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: add E2E Tests for Multi-RPC Migration and Selection #26851

Merged
merged 11 commits into from
Sep 20, 2024

Conversation

salimtb
Copy link
Contributor

@salimtb salimtb commented Sep 3, 2024

Description

This PR introduces a series of end-to-end (E2E) tests to validate the functionality of migrating and selecting multiple RPC configurations in the application. These tests cover different scenarios to ensure that the application handles multi-RPC settings correctly, including migrating to a new RPC setup and selecting RPC endpoints from various interfaces.

Open in GitHub Codespaces

Related issues

Fixes:

Manual testing steps

  1. Run yarn build:test
  2. Run yarn test:e2e:single test/e2e/tests/network/multi-rpc.spec.ts --browser chrome

Screenshots/Recordings

Before

After

Pre-merge author checklist

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

@salimtb salimtb requested a review from a team as a code owner September 3, 2024 09:05
Copy link
Contributor

github-actions bot commented Sep 3, 2024

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@salimtb salimtb force-pushed the salim/add-e2e-test-v21 branch 2 times, most recently from 07132fe to 6420d82 Compare September 3, 2024 15:16
@salimtb salimtb marked this pull request as draft September 17, 2024 13:09
@salimtb salimtb force-pushed the salim/add-e2e-test-v21 branch 5 times, most recently from e29ac13 to 7af4f3d Compare September 19, 2024 10:19
@metamaskbot
Copy link
Collaborator

Builds ready [7af4f3d]
Page Load Metrics (1789 ± 96 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint34023461710370178
domContentLoaded14602238175618388
load14702352178920096
domInteractive147940178
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: -1.68 KiB (-0.04%)
  • ui: 15.45 KiB (0.21%)
  • common: 9.21 KiB (0.11%)

@salimtb salimtb marked this pull request as ready for review September 19, 2024 11:37
@salimtb salimtb requested a review from a team as a code owner September 19, 2024 11:37
Base automatically changed from brian/network-controller-v20-merging-in-v21 to develop September 20, 2024 08:35
@bergeron bergeron requested review from a team as code owners September 20, 2024 08:35
@bergeron bergeron removed request for a team September 20, 2024 16:41
@metamaskbot
Copy link
Collaborator

Builds ready [dcb7596]
Page Load Metrics (1845 ± 107 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint156724401841222107
domContentLoaded154424241816223107
load154824411845222107
domInteractive14149433014
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 32 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

Copy link

sonarcloud bot commented Sep 20, 2024

Quality Gate Failed Quality Gate failed

Failed conditions
0.0% Coverage on New Code (required ≥ 80%)

See analysis details on SonarCloud

@@ -494,7 +495,7 @@ export const NetworkListMenu = ({ onClose }: { onClose: () => void }) => {
<AddRpcUrlModal
onAdded={(url, name) => {
// Note: We could choose to rename the URL if it already exists with a different name
if (rpcUrls.rpcEndpoints?.every((e) => e.url !== url)) {
if (rpcUrls.rpcEndpoints?.every((e) => !URI.equal(e.url, url))) {
Copy link
Contributor

@bergeron bergeron Sep 20, 2024

Choose a reason for hiding this comment

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

This matches the validation done by the network controller, which does not allow duplicates, including edge cases like different casing

@bergeron bergeron merged commit df6ee7f into develop Sep 20, 2024
75 of 77 checks passed
@bergeron bergeron deleted the salim/add-e2e-test-v21 branch September 20, 2024 19:30
@github-actions github-actions bot locked and limited conversation to collaborators Sep 20, 2024
@metamaskbot metamaskbot added the release-12.6.0 Issue or pull request that will be included in release 12.6.0 label Sep 20, 2024
@metamaskbot
Copy link
Collaborator

Builds ready [5bc7d1e]
Page Load Metrics (1829 ± 93 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint156923621832208100
domContentLoaded15572296180019594
load16122312182919393
domInteractive21399558038
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 139 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
release-12.6.0 Issue or pull request that will be included in release 12.6.0 team-assets
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants