-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Stabilize e2e tests for phishing detection #21152
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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. |
chloeYue
changed the title
[DRAFT] Stabilize e2e tests for phishing detection
Stabilize e2e tests for phishing detection
Oct 2, 2023
gauthierpetetin
added
needs-dev-review
PR needs reviews from other engineers (in order to receive required approvals)
in-progress
and removed
needs-dev-review
PR needs reviews from other engineers (in order to receive required approvals)
labels
Oct 2, 2023
HowardBraham
approved these changes
Oct 3, 2023
Codecov ReportAll modified lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #21152 +/- ##
========================================
Coverage 68.57% 68.57%
========================================
Files 1013 1013
Lines 40615 40615
Branches 10854 10854
========================================
Hits 27848 27848
Misses 12767 12767 ☔ View full report in Codecov by Sentry. |
Builds ready [cdb5a82]
Page Load Metrics (866 ± 399 ms)
Bundle size diffs
|
darkwing
approved these changes
Oct 3, 2023
metamaskbot
added
the
release-11.4.0
Issue or pull request that will be included in release 11.4.0
label
Oct 3, 2023
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
release-11.4.0
Issue or pull request that will be included in release 11.4.0
team-extension-platform
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Several e2e testcases about phishing detection are flaky.
Why they are flaky?
After investigation, i think because when we open a malicious website, selenium fetch very quickly all the DOM elements and consider they are complete. When the page redirects to phishing detection page, it dose not re-fetch elements so selenium cannot find buttons to click.
How i resolve it?
I explicitly force selenium to switch to the phishing detection page each time after redirection so it will re-fetch all elements on this page.
Why do i think the fix works
For each testcase, I ran locally 20 times and they all passed.
Fixes #21150