| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <script src="video-test.js"></script> | 4 <script src="video-test.js"></script> |
| 5 <script> | 5 <script> |
| 6 function start() { | 6 function start() { |
| 7 video = document.getElementsByTagName('video')[0]; | 7 video = document.getElementsByTagName('video')[0]; |
| 8 | 8 |
| 9 testExpected("video.canPlayType()", ""); | 9 testException("video.canPlayType()", '"TypeError: Failed to exec
ute \'canPlayType\' on \'HTMLMediaElement\': 1 argument required, but only 0 pre
sent."'); |
| 10 testExpected("video.canPlayType('video/')", ""); | 10 testExpected("video.canPlayType('video/')", ""); |
| 11 testExpected("video.canPlayType('video/blahblah')", ""); | 11 testExpected("video.canPlayType('video/blahblah')", ""); |
| 12 testExpected("video.canPlayType('video/blahblah; codecs=\"blah,
, blah\"')", ""); | 12 testExpected("video.canPlayType('video/blahblah; codecs=\"blah,
, blah\"')", ""); |
| 13 testExpected("video.canPlayType('video/blahblah; codecs=blah')",
""); | 13 testExpected("video.canPlayType('video/blahblah; codecs=blah')",
""); |
| 14 testExpected("video.canPlayType('video/blahblah; codecs=\"blah\"
')", ""); | 14 testExpected("video.canPlayType('video/blahblah; codecs=\"blah\"
')", ""); |
| 15 testExpected("video.canPlayType('video/blahblah; codecs=\"badcon
tent')", ""); | 15 testExpected("video.canPlayType('video/blahblah; codecs=\"badcon
tent')", ""); |
| 16 testExpected("video.canPlayType('video/blahblah; codecs=badconte
nt\"')", ""); | 16 testExpected("video.canPlayType('video/blahblah; codecs=badconte
nt\"')", ""); |
| 17 testExpected("video.canPlayType('video/blahblah; codecs="ba
dcontent"')", ""); | 17 testExpected("video.canPlayType('video/blahblah; codecs="ba
dcontent"')", ""); |
| 18 | 18 |
| 19 endTest(); | 19 endTest(); |
| 20 } | 20 } |
| 21 </script> | 21 </script> |
| 22 </head> | 22 </head> |
| 23 <body onload="start()"> | 23 <body onload="start()"> |
| 24 <video controls></video> | 24 <video controls></video> |
| 25 <p>Test HTMLMediaElement <em>canPlayType()</em> method.</p> | 25 <p>Test HTMLMediaElement <em>canPlayType()</em> method.</p> |
| 26 </body> | 26 </body> |
| 27 </html> | 27 </html> |
| OLD | NEW |