-
Notifications
You must be signed in to change notification settings - Fork 69
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(playwright): skip unloaded iframes #1060
Conversation
@@ -185,7 +185,14 @@ export default class AxeBuilder { | |||
|
|||
private async inject(frames: Frame[]): Promise<void> { | |||
for (const iframe of frames) { | |||
await iframe.evaluate(await this.script()); | |||
const race = new Promise((_, reject) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The newer versions of Playwright with the update to Chrome, combined with our changes to the lazy loaded frame test now make it so Playwright is not loading the lazy loaded iframe when it is outside the viewport.
Playwright does not have a pageload timeout like all the other drivers, and neither does the evaluate function have a timeout option. So this was the only other choice to have the lazy loaded iframe not hang indefinitely.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One comment inline -
Verified with the latest canary-build (4.7.4-62fd241.0) 1. Here is iframes snippets:lazyloadedIframe.html
2. for this iframes - directory has a lazy.html file too./iframes.lazy.html
3. for Playwright 1.44.0 Version and v1.42.1 :TestScript:
Result for 1.44.0: Result for 1.42.1: 4. For Puppeteer v22.9.0 and v22.6.3.test-script:
Results: For 22.6.3 5.for webdriverjs - selenium-webdriver v4.21.0 & v4.19.0:Test-script:
Result: For 4.19.0 5. for CLI (selenium-webdriver v4.21.0 & 4.19.0)-command is
|
Label | Value |
---|---|
Product | axe-core-npm |
Version | 4.9.2-a2f07c5.0 |
Playwright | 1.44.0 & 1.42.1 |
Puppeteer | 22.9.0 & 22.6.3 |
WebdriverIO | _8.36.1 & 8.35.1 _ |
Selenium-webdriver(WebdriverJS & CLI) | _ v4.21.0 & 4.19.0 _ |
OS-Details | _MAC- M1-14.4 & Windows11 _ |
BrowserDetails | Chrome Version 124.0.1 (Official Build) (64-bit) & Firefox 125.0.3 |
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [@axe-core/playwright](https://togithub.com/dequelabs/axe-core-npm) | [`4.9.0` -> `4.9.1`](https://renovatebot.com/diffs/npm/@axe-core%2fplaywright/4.9.0/4.9.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@axe-core%2fplaywright/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@axe-core%2fplaywright/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@axe-core%2fplaywright/4.9.0/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@axe-core%2fplaywright/4.9.0/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>dequelabs/axe-core-npm (@​axe-core/playwright)</summary> ### [`v4.9.1`](https://togithub.com/dequelabs/axe-core-npm/releases/tag/v4.9.1): Release 4.9.1 [Compare Source](https://togithub.com/dequelabs/axe-core-npm/compare/v4.9.0...v4.9.1) #### What's Changed - chore: bump ip from 1.1.8 to 1.1.9 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/dequelabs/axe-core-npm/pull/1023](https://togithub.com/dequelabs/axe-core-npm/pull/1023) - test(cli): add test to cover selenium-webdriver <4.17.0 by [@​michael-siek](https://togithub.com/michael-siek) in [https://github.com/dequelabs/axe-core-npm/pull/1038](https://togithub.com/dequelabs/axe-core-npm/pull/1038) - chore: merge master into develop by [@​github-actions](https://togithub.com/github-actions) in [https://github.com/dequelabs/axe-core-npm/pull/1041](https://togithub.com/dequelabs/axe-core-npm/pull/1041) - chore: bump undici from 5.28.3 to 5.28.4 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/dequelabs/axe-core-npm/pull/1042](https://togithub.com/dequelabs/axe-core-npm/pull/1042) - chore: update test-fixtures to fix lazy load iframe by [@​straker](https://togithub.com/straker) in [https://github.com/dequelabs/axe-core-npm/pull/1053](https://togithub.com/dequelabs/axe-core-npm/pull/1053) - docs(react): Update React support information. Offer axe Developer Hub by [@​ballendq](https://togithub.com/ballendq) in [https://github.com/dequelabs/axe-core-npm/pull/1047](https://togithub.com/dequelabs/axe-core-npm/pull/1047) - fix: Update axe-core to v4.9.1 by [@​straker](https://togithub.com/straker) in [https://github.com/dequelabs/axe-core-npm/pull/1055](https://togithub.com/dequelabs/axe-core-npm/pull/1055) - chore: RC v4.9.1 by [@​github-actions](https://togithub.com/github-actions) in [https://github.com/dequelabs/axe-core-npm/pull/1057](https://togithub.com/dequelabs/axe-core-npm/pull/1057) - chore: Update axe-core to v4.9.1 by [@​attest-team-ci](https://togithub.com/attest-team-ci) in [https://github.com/dequelabs/axe-core-npm/pull/1056](https://togithub.com/dequelabs/axe-core-npm/pull/1056) - fix(playwright): skip unloaded iframes by [@​straker](https://togithub.com/straker) in [https://github.com/dequelabs/axe-core-npm/pull/1060](https://togithub.com/dequelabs/axe-core-npm/pull/1060) - chore: bump the npm-low-risk group across 1 directory with 28 updates by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/dequelabs/axe-core-npm/pull/1061](https://togithub.com/dequelabs/axe-core-npm/pull/1061) - chore: bump ejs from 3.1.9 to 3.1.10 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/dequelabs/axe-core-npm/pull/1049](https://togithub.com/dequelabs/axe-core-npm/pull/1049) - ci: update sync to master to include team-reviewers by [@​michael-siek](https://togithub.com/michael-siek) in [https://github.com/dequelabs/axe-core-npm/pull/1062](https://togithub.com/dequelabs/axe-core-npm/pull/1062) - chore: RC v4.9.1 by [@​github-actions](https://togithub.com/github-actions) in [https://github.com/dequelabs/axe-core-npm/pull/1065](https://togithub.com/dequelabs/axe-core-npm/pull/1065) - Release v4.9.1 by [@​dequejenn](https://togithub.com/dequejenn) in [https://github.com/dequelabs/axe-core-npm/pull/1068](https://togithub.com/dequelabs/axe-core-npm/pull/1068) **Full Changelog**: dequelabs/axe-core-npm@v4.9.0...v4.9.1 </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Enabled. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about these updates again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/camunda/zeebe). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zNjMuNSIsInVwZGF0ZWRJblZlciI6IjM3LjM2My41IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJhdXRvbWVyZ2UiXX0=-->
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [@axe-core/playwright](https://togithub.com/dequelabs/axe-core-npm) | [`4.9.0` -> `4.9.1`](https://renovatebot.com/diffs/npm/@axe-core%2fplaywright/4.9.0/4.9.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@axe-core%2fplaywright/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@axe-core%2fplaywright/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@axe-core%2fplaywright/4.9.0/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@axe-core%2fplaywright/4.9.0/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>dequelabs/axe-core-npm (@​axe-core/playwright)</summary> ### [`v4.9.1`](https://togithub.com/dequelabs/axe-core-npm/releases/tag/v4.9.1): Release 4.9.1 [Compare Source](https://togithub.com/dequelabs/axe-core-npm/compare/v4.9.0...v4.9.1) #### What's Changed - chore: bump ip from 1.1.8 to 1.1.9 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/dequelabs/axe-core-npm/pull/1023](https://togithub.com/dequelabs/axe-core-npm/pull/1023) - test(cli): add test to cover selenium-webdriver <4.17.0 by [@​michael-siek](https://togithub.com/michael-siek) in [https://github.com/dequelabs/axe-core-npm/pull/1038](https://togithub.com/dequelabs/axe-core-npm/pull/1038) - chore: merge master into develop by [@​github-actions](https://togithub.com/github-actions) in [https://github.com/dequelabs/axe-core-npm/pull/1041](https://togithub.com/dequelabs/axe-core-npm/pull/1041) - chore: bump undici from 5.28.3 to 5.28.4 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/dequelabs/axe-core-npm/pull/1042](https://togithub.com/dequelabs/axe-core-npm/pull/1042) - chore: update test-fixtures to fix lazy load iframe by [@​straker](https://togithub.com/straker) in [https://github.com/dequelabs/axe-core-npm/pull/1053](https://togithub.com/dequelabs/axe-core-npm/pull/1053) - docs(react): Update React support information. Offer axe Developer Hub by [@​ballendq](https://togithub.com/ballendq) in [https://github.com/dequelabs/axe-core-npm/pull/1047](https://togithub.com/dequelabs/axe-core-npm/pull/1047) - fix: Update axe-core to v4.9.1 by [@​straker](https://togithub.com/straker) in [https://github.com/dequelabs/axe-core-npm/pull/1055](https://togithub.com/dequelabs/axe-core-npm/pull/1055) - chore: RC v4.9.1 by [@​github-actions](https://togithub.com/github-actions) in [https://github.com/dequelabs/axe-core-npm/pull/1057](https://togithub.com/dequelabs/axe-core-npm/pull/1057) - chore: Update axe-core to v4.9.1 by [@​attest-team-ci](https://togithub.com/attest-team-ci) in [https://github.com/dequelabs/axe-core-npm/pull/1056](https://togithub.com/dequelabs/axe-core-npm/pull/1056) - fix(playwright): skip unloaded iframes by [@​straker](https://togithub.com/straker) in [https://github.com/dequelabs/axe-core-npm/pull/1060](https://togithub.com/dequelabs/axe-core-npm/pull/1060) - chore: bump the npm-low-risk group across 1 directory with 28 updates by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/dequelabs/axe-core-npm/pull/1061](https://togithub.com/dequelabs/axe-core-npm/pull/1061) - chore: bump ejs from 3.1.9 to 3.1.10 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/dequelabs/axe-core-npm/pull/1049](https://togithub.com/dequelabs/axe-core-npm/pull/1049) - ci: update sync to master to include team-reviewers by [@​michael-siek](https://togithub.com/michael-siek) in [https://github.com/dequelabs/axe-core-npm/pull/1062](https://togithub.com/dequelabs/axe-core-npm/pull/1062) - chore: RC v4.9.1 by [@​github-actions](https://togithub.com/github-actions) in [https://github.com/dequelabs/axe-core-npm/pull/1065](https://togithub.com/dequelabs/axe-core-npm/pull/1065) - Release v4.9.1 by [@​dequejenn](https://togithub.com/dequejenn) in [https://github.com/dequelabs/axe-core-npm/pull/1068](https://togithub.com/dequelabs/axe-core-npm/pull/1068) **Full Changelog**: dequelabs/axe-core-npm@v4.9.0...v4.9.1 </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Enabled. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about these updates again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/camunda/zeebe). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zNjMuNSIsInVwZGF0ZWRJblZlciI6IjM3LjM2My41IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJhdXRvbWVyZ2UiXX0=-->
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [@axe-core/playwright](https://togithub.com/dequelabs/axe-core-npm) | [`4.9.0` -> `4.9.1`](https://renovatebot.com/diffs/npm/@axe-core%2fplaywright/4.9.0/4.9.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@axe-core%2fplaywright/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@axe-core%2fplaywright/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@axe-core%2fplaywright/4.9.0/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@axe-core%2fplaywright/4.9.0/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>dequelabs/axe-core-npm (@​axe-core/playwright)</summary> ### [`v4.9.1`](https://togithub.com/dequelabs/axe-core-npm/releases/tag/v4.9.1): Release 4.9.1 [Compare Source](https://togithub.com/dequelabs/axe-core-npm/compare/v4.9.0...v4.9.1) #### What's Changed - chore: bump ip from 1.1.8 to 1.1.9 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/dequelabs/axe-core-npm/pull/1023](https://togithub.com/dequelabs/axe-core-npm/pull/1023) - test(cli): add test to cover selenium-webdriver <4.17.0 by [@​michael-siek](https://togithub.com/michael-siek) in [https://github.com/dequelabs/axe-core-npm/pull/1038](https://togithub.com/dequelabs/axe-core-npm/pull/1038) - chore: merge master into develop by [@​github-actions](https://togithub.com/github-actions) in [https://github.com/dequelabs/axe-core-npm/pull/1041](https://togithub.com/dequelabs/axe-core-npm/pull/1041) - chore: bump undici from 5.28.3 to 5.28.4 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/dequelabs/axe-core-npm/pull/1042](https://togithub.com/dequelabs/axe-core-npm/pull/1042) - chore: update test-fixtures to fix lazy load iframe by [@​straker](https://togithub.com/straker) in [https://github.com/dequelabs/axe-core-npm/pull/1053](https://togithub.com/dequelabs/axe-core-npm/pull/1053) - docs(react): Update React support information. Offer axe Developer Hub by [@​ballendq](https://togithub.com/ballendq) in [https://github.com/dequelabs/axe-core-npm/pull/1047](https://togithub.com/dequelabs/axe-core-npm/pull/1047) - fix: Update axe-core to v4.9.1 by [@​straker](https://togithub.com/straker) in [https://github.com/dequelabs/axe-core-npm/pull/1055](https://togithub.com/dequelabs/axe-core-npm/pull/1055) - chore: RC v4.9.1 by [@​github-actions](https://togithub.com/github-actions) in [https://github.com/dequelabs/axe-core-npm/pull/1057](https://togithub.com/dequelabs/axe-core-npm/pull/1057) - chore: Update axe-core to v4.9.1 by [@​attest-team-ci](https://togithub.com/attest-team-ci) in [https://github.com/dequelabs/axe-core-npm/pull/1056](https://togithub.com/dequelabs/axe-core-npm/pull/1056) - fix(playwright): skip unloaded iframes by [@​straker](https://togithub.com/straker) in [https://github.com/dequelabs/axe-core-npm/pull/1060](https://togithub.com/dequelabs/axe-core-npm/pull/1060) - chore: bump the npm-low-risk group across 1 directory with 28 updates by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/dequelabs/axe-core-npm/pull/1061](https://togithub.com/dequelabs/axe-core-npm/pull/1061) - chore: bump ejs from 3.1.9 to 3.1.10 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/dequelabs/axe-core-npm/pull/1049](https://togithub.com/dequelabs/axe-core-npm/pull/1049) - ci: update sync to master to include team-reviewers by [@​michael-siek](https://togithub.com/michael-siek) in [https://github.com/dequelabs/axe-core-npm/pull/1062](https://togithub.com/dequelabs/axe-core-npm/pull/1062) - chore: RC v4.9.1 by [@​github-actions](https://togithub.com/github-actions) in [https://github.com/dequelabs/axe-core-npm/pull/1065](https://togithub.com/dequelabs/axe-core-npm/pull/1065) - Release v4.9.1 by [@​dequejenn](https://togithub.com/dequejenn) in [https://github.com/dequelabs/axe-core-npm/pull/1068](https://togithub.com/dequelabs/axe-core-npm/pull/1068) **Full Changelog**: dequelabs/axe-core-npm@v4.9.0...v4.9.1 </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Enabled. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about these updates again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/camunda/zeebe). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zNjMuNSIsInVwZGF0ZWRJblZlciI6IjM3LjM2My41IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJhdXRvbWVyZ2UiXX0=-->
Pulled out of #1048. Starting in Playwright 1.41.0 (using Chrome version 121.0.6167.57) Playwright is no longer loading the lazy loaded iframe that is out of view. Updated the version of Playwright and updated the tests to now account for this.
QA notes: Test a lazy loaded iframe with Playwright > 1.41.0 and ensure Playwright will complete an analyze of the page