Title: [107132] trunk/LayoutTests
Revision
107132
Author
jam...@google.com
Date
2012-02-08 13:47:51 -0800 (Wed, 08 Feb 2012)

Log Message

[chromium] Add a layout test for losing the compositor context with a video playing
https://bugs.webkit.org/show_bug.cgi?id=78060

Reviewed by Eric Carlson.

Adds a test to prevent regressions with video playback when we lose the compositor context. This test loads up a
video, forces a frame to be displayed, simulates a lost context, then finishes the test (which causes another
frame to be displayed).

Prior to r106610 this test times out in debug and crashes in ASAN.

* platform/chromium/compositing/lost-compositor-context-with-video-expected.png: Added.
* platform/chromium/compositing/lost-compositor-context-with-video-expected.txt: Added.
* platform/chromium/compositing/lost-compositor-context-with-video.html: Added.

Modified Paths

Added Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (107131 => 107132)


--- trunk/LayoutTests/ChangeLog	2012-02-08 21:46:42 UTC (rev 107131)
+++ trunk/LayoutTests/ChangeLog	2012-02-08 21:47:51 UTC (rev 107132)
@@ -1,3 +1,20 @@
+2012-02-08  James Robinson  <jam...@chromium.org>
+
+        [chromium] Add a layout test for losing the compositor context with a video playing
+        https://bugs.webkit.org/show_bug.cgi?id=78060
+
+        Reviewed by Eric Carlson.
+
+        Adds a test to prevent regressions with video playback when we lose the compositor context. This test loads up a
+        video, forces a frame to be displayed, simulates a lost context, then finishes the test (which causes another
+        frame to be displayed).
+
+        Prior to r106610 this test times out in debug and crashes in ASAN.
+
+        * platform/chromium/compositing/lost-compositor-context-with-video-expected.png: Added.
+        * platform/chromium/compositing/lost-compositor-context-with-video-expected.txt: Added.
+        * platform/chromium/compositing/lost-compositor-context-with-video.html: Added.
+
 2012-02-08  Emil A Eklund  <e...@chromium.org>
 
         Update pixel table test expectations for mac to match new DRT scrollbars

Added: trunk/LayoutTests/platform/chromium/compositing/lost-compositor-context-with-video-expected.png


(Binary files differ)
Property changes on: trunk/LayoutTests/platform/chromium/compositing/lost-compositor-context-with-video-expected.png ___________________________________________________________________

Added: svn:mime-type

Added: trunk/LayoutTests/platform/chromium/compositing/lost-compositor-context-with-video-expected.txt (0 => 107132)


--- trunk/LayoutTests/platform/chromium/compositing/lost-compositor-context-with-video-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/platform/chromium/compositing/lost-compositor-context-with-video-expected.txt	2012-02-08 21:47:51 UTC (rev 107132)
@@ -0,0 +1 @@
+
Property changes on: trunk/LayoutTests/platform/chromium/compositing/lost-compositor-context-with-video-expected.txt
___________________________________________________________________

Added: svn:eol-style

Added: trunk/LayoutTests/platform/chromium/compositing/lost-compositor-context-with-video.html (0 => 107132)


--- trunk/LayoutTests/platform/chromium/compositing/lost-compositor-context-with-video.html	                        (rev 0)
+++ trunk/LayoutTests/platform/chromium/compositing/lost-compositor-context-with-video.html	2012-02-08 21:47:51 UTC (rev 107132)
@@ -0,0 +1,28 @@
+<!DOCTYPE html>
+<!-- This test passes if it doesn't crash or timeout -->
+<html>
+<head>
+<script src=""
+<script>
+if (window.layoutTestController) {
+    layoutTestController.dumpAsText(true);  // This is only useful as a pixel test.
+    layoutTestController.waitUntilDone();
+}
+
+function test() {
+    var v = document.querySelector('video');
+    v.addEventListener("seeked", function() {
+        if (window.layoutTestController) {
+            layoutTestController.display();
+            layoutTestController.loseCompositorContext(1);
+            layoutTestController.display();
+            layoutTestController.notifyDone();
+        }
+    }, false);
+    v.currentTime = 0;
+}
+</script>
+<body _onload_="setSrcByTagName('video', findMediaFile('video', '../../../media/content/test-25fps'));">
+<video _oncanplaythrough_="test();"></video>
+</body>
+</html>
Property changes on: trunk/LayoutTests/platform/chromium/compositing/lost-compositor-context-with-video.html
___________________________________________________________________

Added: svn:eol-style

_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to