test: remove flaky test for binding on error pages (#2952)

I wasn't able to make it consistently pass...
This commit is contained in:
Dmitry Gozman 2020-07-14 21:20:14 -07:00 committed by GitHub
parent 2d5c0328cd
commit 4a00e5c4ea
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -146,22 +146,6 @@ describe('BrowserContext', function() {
expect(popup.mainFrame()).toBeTruthy();
}
});
it('should not call binding on errored pages', async({browser, server}) => {
const context = await browser.newContext();
let gotBinding = 0;
await context.exposeFunction('add', (a, b) => {
gotBinding++;
return a + b;
});
const page = await context.newPage();
server.setRoute('/empty.html', (req, res) => {
res.end(`<script>window.add(2, 3)</script><a href="${server.EMPTY_PAGE}" target="_blank">Click me</a>`);
});
await page.goto(server.EMPTY_PAGE);
await page.click('"Click me"');
await context.close();
expect(gotBinding).toBe(1);
})
});
describe('BrowserContext({userAgent})', function() {