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(capabilities): test that video tag can play video (#2477)
Yury Semikhatsky54f07f9bd6ed
diff --git a/test/assets/movie.mp4 b/test/assets/movie.mp4new file mode 100644index 0000000000..0a4dd5b401Binary files /dev/null and b/test/assets/movie.mp4 differdiff --git a/test/assets/movie.ogv b/test/assets/movie.ogvnew file mode 100644index 0000000000..8702125878Binary files /dev/null and b/test/assets/movie.ogv differdiff --git a/test/assets/video.html b/test/assets/video.htmlnew file mode 100644index 0000000000..c193f924cb--- /dev/null+++ b/test/assets/video.html@@ -0,0 +1,16 @@+<html>+<body>++<video width="400" controls>+ <source src="movie.mp4" type="video/mp4">+ <source src="movie.ogv" type="video/ogg">+ Your browser does not support HTML video.+</video>++<p>+Video courtesy of+<a href="https://www.bigbuckbunny.org/" target="_blank">Big Buck Bunny</a>.+</p>++</body>+</html>\ No newline at end of filediff --git a/test/capabilities.spec.js b/test/capabilities.spec.jsindex ef01be7856..d10bb85ebf 100644--- a/test/capabilities.spec.js+++ b/test/capabilities.spec.js@@ -47,4 +47,9 @@ describe('Capabilities', function() {await page.goto(server.EMPTY_PAGE);expect(await page.evaluate(() => window.testStatus)).toBe('SUCCESS');});+ it.fail(WEBKIT)('should play video', async({page, server}) => {+ await page.goto(server.PREFIX + '/video.html');+ await page.$eval('video', v => v.play());+ await page.$eval('video', v => v.pause());+ });});