| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <title>Test that the painted buffered range contains currentTime.</title> | 2 <title>Test that the painted buffered range contains currentTime.</title> |
| 3 <script src="../../media-resources/media-file.js"></script> | 3 <script src="../../media-resources/media-file.js"></script> |
| 4 <video controls></video> | 4 <video controls></video> |
| 5 <script> | 5 <script> |
| 6 var video = document.querySelector("video"); | 6 var video = document.querySelector("video"); |
| 7 | 7 |
| 8 testRunner.waitUntilDone(); | 8 if (window.testRunner) { |
| 9 testRunner.waitUntilDone(); |
| 10 } |
| 11 |
| 9 video.onended = function() { | 12 video.onended = function() { |
| 13 if (window.testRunner) { |
| 10 testRunner.notifyDone(); | 14 testRunner.notifyDone(); |
| 15 } |
| 11 }; | 16 }; |
| 12 | 17 |
| 13 video.onseeked = function() { | 18 video.onseeked = function() { |
| 14 video.play(); | 19 video.play(); |
| 15 }; | 20 }; |
| 16 | 21 |
| 17 video.onloadedmetadata = function() { | 22 video.onloadedmetadata = function() { |
| 18 video.currentTime = video.duration - 0.5; | 23 video.currentTime = video.duration - 0.5; |
| 19 }; | 24 }; |
| 20 | 25 |
| 21 var mediaFile = findMediaFile("audio", "../../../media/content/test"); | 26 var mediaFile = findMediaFile("audio", "../../../media/content/test"); |
| 22 var type = mimeTypeForExtension(mediaFile.split(".").pop()); | 27 var type = mimeTypeForExtension(mediaFile.split(".").pop()); |
| 23 video.src = "http://127.0.0.1:8000/media/video-throttled-load.cgi?name=" + media
File + "&throttle=5000&nph=1&type=" + type; | 28 video.src = "http://127.0.0.1:8000/media/video-throttled-load.cgi?name=" + media
File + "&throttle=5000&nph=1&type=" + type; |
| 24 </script> | 29 </script> |
| OLD | NEW |