| OLD | NEW |
| 1 <!doctype html> | 1 <!doctype html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <title>getUserMedia({video:true}) creates a stream with a properly initialized v
ideo track</title> | 4 <title>getUserMedia({video:true}) creates a stream with a properly initialized v
ideo track</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#id
l-def-MediaStreamTrack"> | 6 <link rel="help" href="http://dev.w3.org/2011/webrtc/editor/getusermedia.html#id
l-def-MediaStreamTrack"> |
| 7 <link rel="help" href="http://dev.w3.org/2011/webrtc/editor/getusermedia.html#li
fe-cycle-and-media-flow"> | 7 <link rel="help" href="http://dev.w3.org/2011/webrtc/editor/getusermedia.html#li
fe-cycle-and-media-flow"> |
| 8 <link rel="help" href="http://dev.w3.org/2011/webrtc/editor/getusermedia.html#wi
dl-MediaStreamTrack-kind"> | 8 <link rel="help" href="http://dev.w3.org/2011/webrtc/editor/getusermedia.html#wi
dl-MediaStreamTrack-kind"> |
| 9 <link rel="help" href="http://dev.w3.org/2011/webrtc/editor/getusermedia.html#wi
dl-MediaStreamTrack-enabled"> | 9 <link rel="help" href="http://dev.w3.org/2011/webrtc/editor/getusermedia.html#wi
dl-MediaStreamTrack-enabled"> |
| 10 <link rel="help" href="http://dev.w3.org/2011/webrtc/editor/getusermedia.html#wi
dl-MediaStreamTrack-readyState"> | 10 <link rel="help" href="http://dev.w3.org/2011/webrtc/editor/getusermedia.html#wi
dl-MediaStreamTrack-readyState"> |
| 11 </head> | 11 </head> |
| 12 <body> | 12 <body> |
| 13 <p class="instructions" style="display:none">When prompted, accept to share your
video stream.</p> | 13 <p class="instructions" style="display:none">When prompted, accept to share your
video stream.</p> |
| 14 <h1 class="instructions" style="display:none">Description</h1> | 14 <h1 class="instructions" style="display:none">Description</h1> |
| 15 <p class="instructions" style="display:none">This test checks that the video tra
ck of MediaStream | 15 <p class="instructions" style="display:none">This test checks that the video tra
ck of MediaStream |
| 16 object returned by the success callback in getUserMedia is correctly initialized
.</p> | 16 object returned by the success callback in getUserMedia is correctly initialized
.</p> |
| 17 | 17 |
| 18 <div id='log'></div> | 18 <div id='log'></div> |
| 19 <script src=/resources/testharness.js></script> | 19 <script src=/resources/testharness.js></script> |
| 20 <script src=/resources/testharnessreport.js></script> | 20 <script src=/resources/testharnessreport.js></script> |
| 21 <script src=../../../resources/WebIDLParser.js></script> | 21 <script src=/resources/WebIDLParser.js></script> |
| 22 <script src=../../../resources/idlharness.js></script> | 22 <script src=/resources/idlharness.js></script> |
| 23 <script src="../../../resources/vendor-prefix.js" data-prefixed-objects='[{"ance
stors":["navigator"], "name":"getUserMedia"}]'></script> | 23 <script src="/common/vendor-prefix.js" data-prefixed-objects='[{"ancestors":["na
vigator"], "name":"getUserMedia"}]'></script> |
| 24 <script> | 24 <script> |
| 25 var t = async_test("Tests that the video MediaStreamTrack objects are properly i
nitialized", {timeout:10000}); | 25 var t = async_test("Tests that the video MediaStreamTrack objects are properly i
nitialized", {timeout:10000}); |
| 26 var track = null | 26 var track = null |
| 27 var idl_array = new IdlArray(); | 27 var idl_array = new IdlArray(); |
| 28 | 28 |
| 29 idl_array.add_idls("interface EventTarget {\ | 29 idl_array.add_idls("interface EventTarget {\ |
| 30 void addEventListener(DOMString type, EventListener? callback, optional boolea
n capture = false);\ | 30 void addEventListener(DOMString type, EventListener? callback, optional boolea
n capture = false);\ |
| 31 void removeEventListener(DOMString type, EventListener? callback, optional boo
lean capture = false);\ | 31 void removeEventListener(DOMString type, EventListener? callback, optional boo
lean capture = false);\ |
| 32 boolean dispatchEvent(Event event);\ | 32 boolean dispatchEvent(Event event);\ |
| 33 };"); | 33 };"); |
| (...skipping 30 matching lines...) Expand all Loading... |
| 64 assert_equals(track.kind, "video", "The track object is of video kind"); | 64 assert_equals(track.kind, "video", "The track object is of video kind"); |
| 65 // Not clear that this is required by the spec, | 65 // Not clear that this is required by the spec, |
| 66 // see https://www.w3.org/Bugs/Public/show_bug.cgi?id=22212 | 66 // see https://www.w3.org/Bugs/Public/show_bug.cgi?id=22212 |
| 67 assert_true(track.enabled, "The track object is enabed"); | 67 assert_true(track.enabled, "The track object is enabed"); |
| 68 t.done(); | 68 t.done(); |
| 69 }), function (error) {}); | 69 }), function (error) {}); |
| 70 }); | 70 }); |
| 71 </script> | 71 </script> |
| 72 </body> | 72 </body> |
| 73 </html> | 73 </html> |
| OLD | NEW |