Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.
TypeScript automationchromechromiume2e-testingelectronend-to-end-testingfirefoxjavascriptplaywrighttesttest-automationtestingtesting-toolswebwebkit
test: speculative fix for flaky role selectors test (#36767)
Max Schmitt5e73040235a3
diff --git a/tests/library/role-utils.spec.ts b/tests/library/role-utils.spec.tsindex 4bde350c2d..d894edbb29 100644--- a/tests/library/role-utils.spec.ts+++ b/tests/library/role-utils.spec.ts@@ -439,11 +439,12 @@ test('control embedded in a target element', async ({ page }) => {expect.soft(await getNameAndRole(page, 'h1')).toEqual({ role: 'heading', name: 'Foo bar' });});-test('svg role=presentation', async ({ page }) => {+test('svg role=presentation', async ({ page, server }) => {test.info().annotations.push({ type: 'issue', description: 'https://github.com/microsoft/playwright/issues/26809' });+ await page.goto(server.EMPTY_PAGE);await page.setContent(`- <img src="http://example.com/image.png" alt="Code is Poetry." />+ <img src="pptr.png" alt="Code is Poetry." /><svg viewBox="0 0 100 100" width="16" height="16" xmlns="http://www.w3.org/2000/svg" role="presentation" focusable="false"><circle cx="50" cy="50" r="50"></circle></svg>`);expect.soft(await getNameAndRole(page, 'img')).toEqual({ role: 'img', name: 'Code is Poetry.' });