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: eval promise with disabled javascript (#9552)
Yury Semikhatsky8397fac178ef
diff --git a/tests/browsercontext-basic.spec.ts b/tests/browsercontext-basic.spec.tsindex d4dd082c2c..7975dafd76 100644--- a/tests/browsercontext-basic.spec.ts+++ b/tests/browsercontext-basic.spec.ts@@ -218,6 +218,14 @@ it('should be able to navigate after disabling javascript', async ({ browser, seawait context.close();});+it('should not hang on promises after disabling javascript', async ({ browserName, contextFactory }) => {+ it.fixme(browserName === 'webkit' || browserName === 'firefox');+ const context = await contextFactory({ javaScriptEnabled: false });+ const page = await context.newPage();+ expect(await page.evaluate(() => 1)).toBe(1);+ expect(await page.evaluate(async () => 2)).toBe(2);+});+it('should work with offline option', async ({ browser, server }) => {const context = await browser.newContext({ offline: true });const page = await context.newPage();