Changeset 53147 in webkit
- Timestamp:
- Jan 12, 2010 10:33:09 AM (14 years ago)
- Location:
- trunk/LayoutTests
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r53146 r53147 1 2010-01-12 Philippe Normand <pnormand@igalia.com> 2 3 Reviewed by Eric Carlson. 4 5 [GTK] Failing media/video-seek-past-end-playing.html 6 https://bugs.webkit.org/show_bug.cgi?id=33015 7 8 Listen on timeupdate event instead of waiting a fixed amount of 9 time, which is prone to test flackyness. 10 11 * media/audio-mpeg-supported.html: 12 * media/video-seek-past-end-playing.html: 13 * platform/gtk/Skipped: 14 1 15 2010-01-12 Eric Carlson <eric.carlson@apple.com> 2 16 -
trunk/LayoutTests/media/audio-mpeg-supported.html
r50063 r53147 8 8 <script src=video-test.js></script> 9 9 <script> 10 var timeupdateEventCount = 0; 10 11 mediaElement = document.getElementsByTagName('audio')[0]; 11 12 … … 19 20 testExpected("mediaElement.currentTime", 0); 20 21 mediaElement.play(); 21 setTimeout(testCurrentTime, 500)22 22 }); 23 23 24 function t estCurrentTime()24 function timeupdate() 25 25 { 26 testExpected("mediaElement.currentTime", 0, '>'); 27 endTest(); 26 ++timeupdateEventCount; 27 28 // wait 2 timeupdate events so we are sure the media engine is 29 // playing the media. 30 if (timeupdateEventCount == 2) { 31 // make sure time is advancing 32 testExpected("mediaElement.currentTime", 0, '>'); 33 // reset the counter to prevent infinite loop if the 34 // test is re-executed manually. 35 timeupdateEventCount = 0; 36 endTest(); 37 } 28 38 } 29 39 40 mediaElement.addEventListener("timeupdate", timeupdate); 30 41 waitForEvent('play'); 31 42 -
trunk/LayoutTests/media/video-seek-past-end-playing.html
r50063 r53147 1 <html> 2 <body> 3 1 4 <video loop controls></video> 2 5 <p>Test that seeking video with 'loop' past it's end rewinds to the beginning and continues playback.</p> … … 4 7 <script src=video-test.js></script> 5 8 <script> 9 var timeupdateEventCount = 0; 6 10 7 11 waitForEvent('canplaythrough', function () { … … 9 13 run("video.play()"); 10 14 testExpected("video.paused", false); 11 setTimeout(timeCheck1, 200);12 15 }); 13 16 14 function time Check1()17 function timeupdate() 15 18 { 16 // make sure time is advancing, seek past end 17 consoleWrite(""); 18 testExpected("video.paused", false); 19 testExpected("mediaElement.currentTime", 0, '>'); 20 run("video.currentTime = 500"); 21 setTimeout(timeCheck2, 200); 19 ++timeupdateEventCount; 20 21 // wait 2 timeupdate events so we are sure the media engine is 22 // playing the media. 23 if (timeupdateEventCount == 2) { 24 consoleWrite(""); 25 testExpected("video.paused", false); 26 // make sure time is advancing and seek past end 27 testExpected("mediaElement.currentTime", 0, '>'); 28 run("video.currentTime = 500"); 29 setTimeout(seekCheck, 200); 30 } 22 31 } 23 32 24 function timeCheck2()33 function seekCheck() 25 34 { 26 35 consoleWrite(""); … … 28 37 testExpected("mediaElement.currentTime", 0, '>'); 29 38 consoleWrite(""); 39 // reset the counter to prevent infinite loop if the 40 // test is re-executed manually. 41 timeupdateEventCount = 0; 30 42 endTest(); 31 43 } 32 44 45 mediaElement.addEventListener("timeupdate", timeupdate); 33 46 var mediaFile = findMediaFile("video", "content/test"); 34 47 run("video.src = '" + mediaFile + "'"); 35 48 consoleWrite(""); 36 49 </script> 50 </body> 51 </html>
Note: See TracChangeset
for help on using the changeset viewer.