test: add failing test for clicking certain elements (#4282)
References #4281
This commit is contained in:
parent
8f8e77492d
commit
145e8680b1
@ -34,6 +34,19 @@ module.exports.addTests = function({testRunner, expect}) {
|
|||||||
await page.click('button');
|
await page.click('button');
|
||||||
expect(await page.evaluate(() => result)).toBe('Clicked');
|
expect(await page.evaluate(() => result)).toBe('Clicked');
|
||||||
});
|
});
|
||||||
|
// @see https://github.com/GoogleChrome/puppeteer/issues/4281
|
||||||
|
xit('should click on a span with an inline element inside', async({page, server}) => {
|
||||||
|
await page.setContent(`
|
||||||
|
<style>
|
||||||
|
span::before {
|
||||||
|
content: 'q';
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<span onclick='javascript:window.CLICKED=42'></span>
|
||||||
|
`);
|
||||||
|
await page.click('span');
|
||||||
|
expect(await page.evaluate(() => window.CLICKED)).toBe(42);
|
||||||
|
});
|
||||||
it('should click the button after navigation ', async({page, server}) => {
|
it('should click the button after navigation ', async({page, server}) => {
|
||||||
await page.goto(server.PREFIX + '/input/button.html');
|
await page.goto(server.PREFIX + '/input/button.html');
|
||||||
await page.click('button');
|
await page.click('button');
|
||||||
|
Loading…
Reference in New Issue
Block a user