Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix E2E confirmation flakiness and object not extensible #7802

Merged
merged 9 commits into from
Nov 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/components/UI/TransactionReview/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ class TransactionReview extends PureComponent {
/**
* Error blockaid transaction execution, undefined value signifies no error.
*/
error: PropTypes.oneOf[(PropTypes.bool, PropTypes.string)],
error: PropTypes.oneOfType([PropTypes.string, PropTypes.bool]),
/**
* Whether or not basic gas estimates have been fetched
*/
Expand Down
2 changes: 1 addition & 1 deletion bitrise.yml
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ workflows:
asdf global nodejs 18.18
asdf plugin add yarn
asdf list all yarn
asdf install yarn latest
asdf install yarn 1.22.19
Copy link
Contributor Author

@vinistevam vinistevam Nov 14, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just to fix the pipeline until yarn fixes the artifacts in their repo. Once it's fixed we can revert back to latest

asdf global yarn 1.22.19
title: Install node and yarn
- yarn@0:
Expand Down
10 changes: 9 additions & 1 deletion e2e/fixtures/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,17 @@ import { DEFAULT_GANACHE_PORT } from '../../app/util/test/ganache';
import { DEFAULT_FIXTURE_SERVER_PORT } from './fixture-server';
import { DEFAULT_DAPP_SERVER_PORT } from './fixture-helper';

function transformToValidPort(defaultPort, pid) {
// Improve uniqueness by using a simple transformation
const transformedPort = (parseInt(pid, 10) % 100000) + defaultPort;

// Ensure the transformed port falls within the valid port range (0-65535)
return transformedPort % 65536;
}

function getServerPort(defaultPort) {
if (process.env.CI) {
return defaultPort + (parseInt(process.pid, 10) % 10);
return transformToValidPort(defaultPort, process.pid);
}
return defaultPort;
}
Expand Down
Loading