Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Puppeteer/CDP for WPT

Based on @jugglinmike ExecutorCDP prototype

grep 'API status' tools/pyppeteer/ -r | grep -Eo "'[A-Z][A-Za-z]+\.[A-Za-z]+'" | sort | uniq -c | sort -rn
5 'Input.dispatchMouseEvent'
4 'Runtime.releaseObject'
4 'Input.dispatchKeyEvent'
3 'Runtime.evaluate'
2 'Page.navigate'
1 'Target.sendMessageToTarget'
1 'Target.getTargets'
1 'Target.closeTarget'
1 'Target.attachToTarget'
1 'Security.setOverrideCertificateErrors'
1 'Security.setIgnoreCertificateErrors'
1 'Security.handleCertificateError'
1 'Security.enable'
1 'Security.certificateError'
1 'Runtime.getProperties'
1 'Page.enable'
1 'Page.captureScreenshot'
1 'DOM.getBoxModel'
1 'DOM.focus'
1 'Browser.setWindowBounds'
1 'Browser.getWindowForTarget'

Puppeteer APIs needed to run full WPT Based on @Hexcles wpt-puppeteer prototype

Puppeteer.launch
Browser.pages
Browser.newPage
Browser.close
Page.evaluate & Page.$eval
Page.exposeFunction
Page.click
Page.goto
Page.screenshot
Page.type
Page.viewport
Keyboard.down
Keyboard.up
Mouse.up
Mouse.down
Mouse.move
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment