Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(166)

Side by Side Diff: third_party/WebKit/LayoutTests/media/video-source-type-params.html

Issue 2102433003: Convert video-source* tests to testharness.js (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 <body> 1 <!DOCTYPE html>
2 <script src=media-file.js></script> 2 <title>Test "source" element "type" attribute with "params".</title>
3 <!-- TODO(foolip): Convert test to testharness.js. crbug.com/588956 3 <script src="../resources/testharness.js"></script>
4 (Please avoid writing new tests using video-test.js) --> 4 <script src="../resources/testharnessreport.js"></script>
5 <script src=video-test.js></script> 5 <script src="media-file.js"></script>
6 <script> 6 <video>
7 waitForEvent('loadstart', function () {
8 video = mediaElement = document.getElementsByTagName('video')[0];
9 testExpected("stripExtension(relativeURL(video.currentSrc))", stripExten sion(findMediaFile("video", "content/test")));
10 endTest();
11 } );
12 </script>
13 <video controls>
14 <source src=content/bogus.mpeg type="video/blahblah"> 7 <source src=content/bogus.mpeg type="video/blahblah">
15 <source src=content/test.mp4 type="video/mpeg; codecs=&quot;avc1.4D400C&quot ;"> 8 <source src=content/test.mp4 type="video/mpeg; codecs=&quot;avc1.4D400C&quot ;">
16 <source src=content/test.ogv type="video/ogg; codecs=&quot;theora,vorbis&quo t;"> 9 <source src=content/test.ogv type="video/ogg; codecs=&quot;theora,vorbis&quo t;">
17 <source src=content/error2.mpeg type=video/mpeg> 10 <source src=content/error2.mpeg type=video/mpeg>
18 </video> 11 </video>
12 <script>
13 async_test(function(t) {
14 var video = document.querySelector("video");
15
16 video.onloadstart = t.step_func_done(function() {
17 var url = video.currentSrc;
18 assert_equals(url.substr(url.lastIndexOf("/media/") + 7), findMediaFile( "video", "content/test"));
19 });
20 });
21 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698