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

Side by Side Diff: third_party/WebKit/LayoutTests/imported/wpt/mediacapture-streams/MediaStream-MediaElement-srcObject.html

Issue 2010163003: Fix paths of testharness*, WebIDLParser.js, idlharness.js, vendor-prefix.js for remaining files … (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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 <!doctype html> 1 <!doctype html>
2 <html> 2 <html>
3 <head> 3 <head>
4 <title>Assigning mediastream to a video element</title> 4 <title>Assigning mediastream to a video element</title>
5 <link rel="author" title="Dominique Hazael-Massieux" href="mailto:dom@w3.org"/> 5 <link rel="author" title="Dominique Hazael-Massieux" href="mailto:dom@w3.org"/>
6 <link rel="help" href="http://dev.w3.org/2011/webrtc/editor/getusermedia.html#na vigatorusermedia"> 6 <link rel="help" href="http://dev.w3.org/2011/webrtc/editor/getusermedia.html#na vigatorusermedia">
7 </head> 7 </head>
8 <body> 8 <body>
9 <p class="instructions" style="display:none">When prompted, accept to share your video stream.</p> 9 <p class="instructions" style="display:none">When prompted, accept to share your video stream.</p>
10 <h1 class="instructions" style="display:none">Description</h1> 10 <h1 class="instructions" style="display:none">Description</h1>
11 <p class="instructions" style="display:none">This test checks that the MediaStre am object returned by 11 <p class="instructions" style="display:none">This test checks that the MediaStre am object returned by
12 the success callback in getUserMedia can be properly assigned to a video element 12 the success callback in getUserMedia can be properly assigned to a video element
13 via the <code>srcObject</code> attribute.</p> 13 via the <code>srcObject</code> attribute.</p>
14 14
15 <video id="vid"></video> 15 <video id="vid"></video>
16 16
17 <div id='log'></div> 17 <div id='log'></div>
18 <script src=/resources/testharness.js></script> 18 <script src=/resources/testharness.js></script>
19 <script src=/resources/testharnessreport.js></script> 19 <script src=/resources/testharnessreport.js></script>
20 <script src="../../../resources/vendor-prefix.js" data-prefixed-objects='[{"ance stors":["navigator"], "name":"getUserMedia"}]' data-prefixed-prototypes='[{"ance stors":["HTMLMediaElement"],"name":"srcObject"}]'></script> 20 <script src="/common/vendor-prefix.js" data-prefixed-objects='[{"ancestors":["na vigator"], "name":"getUserMedia"}]' data-prefixed-prototypes='[{"ancestors":["HT MLMediaElement"],"name":"srcObject"}]'></script>
21 <script> 21 <script>
22 var vid = document.getElementById("vid"); 22 var vid = document.getElementById("vid");
23 var t = async_test("Tests that a MediaStream can be assigned to a video element with srcObject", {timeout: 10000}); 23 var t = async_test("Tests that a MediaStream can be assigned to a video element with srcObject", {timeout: 10000});
24 t.step(function() { 24 t.step(function() {
25 navigator.getUserMedia({video: true}, t.step_func(function (stream) { 25 navigator.getUserMedia({video: true}, t.step_func(function (stream) {
26 var testOncePlaying = function() { 26 var testOncePlaying = function() {
27 assert_equals(vid.played.length, 1, "A MediaStream's timeline always cons ists of a single range"); 27 assert_equals(vid.played.length, 1, "A MediaStream's timeline always cons ists of a single range");
28 assert_equals(vid.played.start(0), 0, "A MediaStream's timeline always co nsists of a single range"); 28 assert_equals(vid.played.start(0), 0, "A MediaStream's timeline always co nsists of a single range");
29 assert_equals(vid.played.end(0), vid.currentTime, "A MediaStream's timeli ne always consists of a single range"); 29 assert_equals(vid.played.end(0), vid.currentTime, "A MediaStream's timeli ne always consists of a single range");
30 assert_equals(vid.readyState, vid.HAVE_ENOUGH_DATA, "Upon selecting a med ia stream, the UA sets readyState to HAVE_ENOUGH_DATA"); 30 assert_equals(vid.readyState, vid.HAVE_ENOUGH_DATA, "Upon selecting a med ia stream, the UA sets readyState to HAVE_ENOUGH_DATA");
(...skipping 15 matching lines...) Expand all
46 assert_equals(vid.defaultPlaybackRate, 1, "playback rate is always 1"); 46 assert_equals(vid.defaultPlaybackRate, 1, "playback rate is always 1");
47 assert_equals(vid.playbackRate, 1, "playback rate is always 1"); 47 assert_equals(vid.playbackRate, 1, "playback rate is always 1");
48 assert_equals(vid.buffered.length, 0, "A MediaStream cannot be preloaded. T herefore, there is no buffered timeranges"); 48 assert_equals(vid.buffered.length, 0, "A MediaStream cannot be preloaded. T herefore, there is no buffered timeranges");
49 assert_equals(vid.duration, Infinity, " A MediaStream does not have a pre-de fined duration. "); 49 assert_equals(vid.duration, Infinity, " A MediaStream does not have a pre-de fined duration. ");
50 assert_equals(vid.startDate, NaN, " A MediaStream does not specify a timelin e offset"); 50 assert_equals(vid.startDate, NaN, " A MediaStream does not specify a timelin e offset");
51 }), function(error) {}); 51 }), function(error) {});
52 }); 52 });
53 </script> 53 </script>
54 </body> 54 </body>
55 </html> 55 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698