Title: [231334] trunk/LayoutTests
- Revision
- 231334
- Author
- [email protected]
- Date
- 2018-05-03 16:43:45 -0700 (Thu, 03 May 2018)
Log Message
Revert the unitended changes in r231329.
* http/tests/media/video-play-stall.html: Replaced with LayoutTests/http/tests/media/video-play-stall.html.
* platform/mac/TestExpectations:
Modified Paths
Added Paths
Removed Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (231333 => 231334)
--- trunk/LayoutTests/ChangeLog 2018-05-03 23:34:54 UTC (rev 231333)
+++ trunk/LayoutTests/ChangeLog 2018-05-03 23:43:45 UTC (rev 231334)
@@ -1,3 +1,10 @@
+2018-05-03 Ryosuke Niwa <[email protected]>
+
+ Revert the unitended changes in r231329.
+
+ * http/tests/media/video-play-stall.html: Replaced with LayoutTests/http/tests/media/video-play-stall.html.
+ * platform/mac/TestExpectations:
+
2018-05-03 Chris Dumez <[email protected]>
Stop using an iframe's id as fallback if its name attribute is not set
Deleted: trunk/LayoutTests/http/tests/media/video-play-stall.html (231333 => 231334)
--- trunk/LayoutTests/http/tests/media/video-play-stall.html 2018-05-03 23:34:54 UTC (rev 231333)
+++ trunk/LayoutTests/http/tests/media/video-play-stall.html 2018-05-03 23:43:45 UTC (rev 231334)
@@ -1,127 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<title>'stalled' event test</title>
-<script src=""
-<xscript src=""
-<xscript src=""
-<script>
-
- var playCount = 0;
-
- function start()
- {
- return;
- alert('loaded!');
- findMediaElement();
- waitForEvent('durationchange');
- waitForEvent('loadedmetadata');
- waitForEvent('loadeddata');
-
- mediaElement.addEventListener('canplay', function () {
- // 'stalled' takes three seconds to fire, so 'canplay' may fire more than once
- // depending on how the engine parses incoming media data.
- if (++playCount > 1)
- return;
- consoleWrite("EVENT(canplay)");
- run("video.play()");
- } );
-
- waitForEvent('stalled', function () {
- testExpected("video.currentTime", 0, "!=");
- testExpected("video.playbackRate", 1, "===");
- testExpected("video.paused", false, "===");
- endTest();
- } );
-
- var mediaFile = findMediaFile("video", "../../../../media/content/long-test");
- var mimeType = mimeTypeForFile(mediaFile);
- alert("http://127.0.0.1:8000/media/resources/serve-video.php?name=" + mediaFile + "&type=" + mimeType + "&stallOffset=100000&stallDuration=60&chunkSize=1024");
- video.src = "" + mediaFile + "&type=" + mimeType + "&stallOffset=100000&stallDuration=60&chunkSize=1024";
- }
-
-</script>
-</head>
-<body _onload_="setTimeout(start, 0)">
-<!--<video autoplay controls>
- <source src=""
-</video>-->
-<script>
-
-if (window.testRunner) {
- testRunner.waitUntilDone();
- setTimeout(() => testRunner.notifyDone(), 3000);
-}
-
-const source = `<!DOCTYPE html>
-<video autoplay controls>
- <source src=""
-</video>`;
-
-function insertFrameWithVideo() {
- const iframe = document.createElement('iframe');
- document.body.append(iframe);
- iframe.contentDocument.open();
- iframe.contentDocument.write(source);
- iframe.contentDocument.write(`<script>
- document.querySelector('video').addEventListener('stalled', () => top.deleteFrame(window.frameElement));
-</scr` + `ipt>`);
- iframe.contentDocument.close();
-}
-
-const maxFrameCount = 5;
-let remainigFrameCount;
-function addFrames() {
- remainigFrameCount = maxFrameCount;
- for (let i = 0; i < maxFrameCount; i++)
- insertFrameWithVideo();
-}
-
-function deleteFrame(iframe) {
- iframe.contentDocument.open();
- iframe.contentDocument.write('');
- iframe.contentDocument.close('');
- setTimeout(() => iframe.remove(), 5000);
-// iframe.remove();
- remainigFrameCount--;
- if (!remainigFrameCount)
- addFrames();
-}
-
-addFrames();
-
-/*
-
-function gcAndFinish() {
- for (let i = 0; i < 5000; i++) {
- document.createElement('video');
- document.createElement('source');
- }
- if (window.GCController)
- GCController.collect();
- if (window.GCController)
- GCController.collect();
- if (window.GCController)
- GCController.collect();
- if (window.testRunner)
- testRunner.notifyDone();
-}
-
-function prepare() {
- document.querySelector('video').addEventListener('stalled', deleteVideo);
-}
-
-function deleteVideo() {
- const iframe = document.createElement('iframe');
- document.body.appendChild(iframe);
- iframe.contentDocument.body.appendChild(this);
- iframe.remove();
- setTimeout(gcAndFinish, 0);
-}
-
-prepare();*/
-
-</script>
-<p>Test that a stalled event is sent when media loading stalls.</p>
-</body>
-</html>
Copied: trunk/LayoutTests/http/tests/media/video-play-stall.html (from rev 231328, trunk/LayoutTests/http/tests/media/video-play-stall.html) (0 => 231334)
--- trunk/LayoutTests/http/tests/media/video-play-stall.html (rev 0)
+++ trunk/LayoutTests/http/tests/media/video-play-stall.html 2018-05-03 23:43:45 UTC (rev 231334)
@@ -0,0 +1,45 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <title>'stalled' event test</title>
+ <script src=""
+ <script src=""
+ <script>
+
+ var playCount = 0;
+
+ function start()
+ {
+ findMediaElement();
+ waitForEvent('durationchange');
+ waitForEvent('loadedmetadata');
+ waitForEvent('loadeddata');
+
+ mediaElement.addEventListener('canplay', function () {
+ // 'stalled' takes three seconds to fire, so 'canplay' may fire more than once
+ // depending on how the engine parses incoming media data.
+ if (++playCount > 1)
+ return;
+ consoleWrite("EVENT(canplay)");
+ run("video.play()");
+ } );
+
+ waitForEvent('stalled', function () {
+ testExpected("video.currentTime", 0, "!=");
+ testExpected("video.playbackRate", 1, "===");
+ testExpected("video.paused", false, "===");
+ endTest();
+ } );
+
+ var mediaFile = findMediaFile("video", "../../../../media/content/long-test");
+ var mimeType = mimeTypeForFile(mediaFile);
+ video.src = "" + mediaFile + "&type=" + mimeType + "&stallOffset=100000&stallDuration=60&chunkSize=1024";
+ }
+
+ </script>
+ </head>
+ <body _onload_="setTimeout(start, 0)">
+ <video controls></video>
+ <p>Test that a stalled event is sent when media loading stalls.</p>
+ </body>
+</html>
Property changes on: trunk/LayoutTests/http/tests/media/video-play-stall.html
___________________________________________________________________
Added: svn:mergeinfo
+/trunk/LayoutTests/http/tests/media/video-play-stall.html:53455
\ No newline at end of property
Modified: trunk/LayoutTests/platform/mac/TestExpectations (231333 => 231334)
--- trunk/LayoutTests/platform/mac/TestExpectations 2018-05-03 23:34:54 UTC (rev 231333)
+++ trunk/LayoutTests/platform/mac/TestExpectations 2018-05-03 23:43:45 UTC (rev 231334)
@@ -1726,6 +1726,8 @@
webkit.org/b/181831 [ HighSierra+ ] fast/forms/searchfield-heights.html [ Pass Failure ]
+webkit.org/b/182589 fast/dom/adopt-node-crash-2.html [ Pass Failure ]
+
webkit.org/b/181612 [ Debug ] webanimations/animation-opacity-animation-crash.html [ Pass Failure ]
webkit.org/b/172241 http/tests/appcache/404-resource-with-slow-main-resource.php [ Pass Failure ]
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes