OLD | NEW |
1 <html lang="en"> | 1 <html lang="en"> |
2 <head> | 2 <head> |
3 <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | 3 <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> |
4 <title><video> and <source> error test</title> | 4 <title><video> and <source> error test</title> |
5 <script src=video-test.js></script> | 5 <script src=video-test.js></script> |
6 | 6 |
7 <script> | 7 <script> |
8 | 8 |
9 var sources = []; | 9 var sources = []; |
10 var errorCount = 0; | 10 var errorCount = 0; |
11 var expectedErrorCount = 5; | 11 var expectedErrorCount = 4; |
12 | 12 |
13 function errorEvent(evt) | 13 function errorEvent(evt) |
14 { | 14 { |
15 consoleWrite(""); | 15 consoleWrite(""); |
16 | 16 |
17 var ndx; | 17 var ndx; |
18 for (ndx = 0; ndx < sources.length; ndx++) { | 18 for (ndx = 0; ndx < sources.length; ndx++) { |
19 if (sources[ndx] == evt.target) | 19 if (sources[ndx] == evt.target) |
20 break; | 20 break; |
21 } | 21 } |
(...skipping 20 matching lines...) Expand all Loading... |
42 | 42 |
43 findMediaElement(); | 43 findMediaElement(); |
44 } | 44 } |
45 </script> | 45 </script> |
46 </head> | 46 </head> |
47 | 47 |
48 <body> | 48 <body> |
49 | 49 |
50 <video onloadstart="start()" controls> | 50 <video onloadstart="start()" controls> |
51 <source id=missing-src type="video/blahblah"> | 51 <source id=missing-src type="video/blahblah"> |
52 <source id=bogus-type src=content/test.mp4 type="video/blahblah"> | 52 <source id=bogus-type src=content/test.ogv type="video/blahblah"> |
53 <source id=unsupported-media-query src=content/test.mp4 media=print> | 53 <source id=empty-src src="" type="video/ogg"> |
54 <source id=empty-src src="" type="video/mp4"> | |
55 <source id=no-extension-no-type src=nonexistent> | 54 <source id=no-extension-no-type src=nonexistent> |
56 </video> | 55 </video> |
57 | 56 |
58 <p>Test that 'error' events are fired from <source> element when i
t can not be used.</p> | 57 <p>Test that 'error' events are fired from <source> element when i
t can not be used.</p> |
59 | 58 |
60 </body> | 59 </body> |
61 </html> | 60 </html> |
OLD | NEW |