Index: third_party/WebKit/LayoutTests/media/video-played-ranges-1.html |
diff --git a/third_party/WebKit/LayoutTests/media/video-played-ranges-1.html b/third_party/WebKit/LayoutTests/media/video-played-ranges-1.html |
index 801316082e3e7c06a56f3a75f86c4aa59777b0c6..17406f8596eb3a61225d5fb415a75b3c16129dff 100644 |
--- a/third_party/WebKit/LayoutTests/media/video-played-ranges-1.html |
+++ b/third_party/WebKit/LayoutTests/media/video-played-ranges-1.html |
@@ -2,23 +2,25 @@ |
<head> |
<title>Test of 'played' attribute</title> |
<script src=media-file.js></script> |
+ <!-- TODO(philipj): Convert test to testharness.js. crbug.com/588956 |
+ (Please avoid writing new tests using video-test.js) --> |
<script src=video-test.js></script> |
<script src=video-played.js></script> |
<script> |
- |
- var testFunctions = |
- [ |
+ |
+ var testFunctions = |
+ [ |
PlayWithNoRanges, |
JumpAndPlayFwd, |
JumpBackAndPlayToNewRange, |
JumpAndExtendRangeStart, |
JumpAndExtendRangeEnd, |
]; |
- |
+ |
// NOTE: Detailed results are not printed for this test because time values are different from machine |
// to machine and run to run. Commenting out the following line turns on detailed logging back on, which |
// can be useful for debugging test failure. |
- disableFullTestDetailsPrinting(); |
+ disableFullTestDetailsPrinting(); |
function PlayWithNoRanges() |
{ |
@@ -30,7 +32,7 @@ |
startPlayingInNewRange(); |
} |
- |
+ |
function JumpAndPlayFwd() |
{ |
consoleWrite("<br><b><em>Test jumping forward into a new range and play</em></b>"); |
@@ -44,44 +46,44 @@ |
startPlayingInNewRange(); |
} |
- |
+ |
function JumpBackAndPlayToNewRange() |
{ |
consoleWrite("<br><b><em>Test jumping backwards into a new range and play, should insert new range</em></b>"); |
- |
+ |
var newTime = 3.00; |
runSilently("video.currentTime = " + newTime); |
- |
+ |
currentTimeRange = 1; |
willPauseInExistingRange = false; |
willExtendAnExistingRange = false; |
startPlayingInNewRange(); |
} |
- |
+ |
function JumpAndExtendRangeStart() |
{ |
consoleWrite("<br><b><em>Test playing into an existing range, should extend range start</em></b>"); |
- |
+ |
currentTimeRange = 1; |
var newTime = (video.played.start(currentTimeRange) - 0.05).toFixed(2); |
runSilently("video.currentTime = " + newTime); |
- |
+ |
expectedStartTimes[currentTimeRange] = newTime; |
willPauseInExistingRange = true; |
willExtendAnExistingRange = true; |
startPlaying(); |
} |
- |
+ |
function JumpAndExtendRangeEnd() |
{ |
consoleWrite("<br><b><em>Test jumping into an existing range and play beyond end, should extend range end</em></b>"); |
- |
+ |
currentTimeRange = 1; |
- |
+ |
var newTime = (video.played.end(currentTimeRange) - 0.05).toFixed(2); |
runSilently("video.currentTime = " + newTime); |
- |
+ |
willPauseInExistingRange = false; |
willExtendAnExistingRange = true; |
playForMillisecs(30); |