Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test(capabilities): test that video tag can play video #2477

Merged
merged 2 commits into from
Jun 6, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added test/assets/movie.mp4
Binary file not shown.
Binary file added test/assets/movie.ogv
Binary file not shown.
16 changes: 16 additions & 0 deletions test/assets/video.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<html>
<body>

<video width="400" controls>
<source src="movie.mp4" type="video/mp4">
<source src="movie.ogv" type="video/ogg">
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Last time I tried this, our WebKit on mac did not play the ogg. It does a range request that's not supported by our test server.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's unfortunate, marking it as failing in WebKit for now anyway.

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>
5 changes: 5 additions & 0 deletions test/capabilities.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -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());
});
});