Index: LayoutTests/compositing/video-page-visibility.html |
diff --git a/LayoutTests/compositing/video-page-visibility.html b/LayoutTests/compositing/video-page-visibility.html |
index a813df3c6597a2d3aff6d79756007193d9fc75fe..d4026f51de9acef701ccb17ff044548e611c83e6 100644 |
--- a/LayoutTests/compositing/video-page-visibility.html |
+++ b/LayoutTests/compositing/video-page-visibility.html |
@@ -1,5 +1,6 @@ |
<html> |
<head> |
+ <script src="../resources/run-after-display.js"></script> |
<style> |
video { |
width: 400px; |
@@ -20,10 +21,10 @@ |
video.src = 'resources/video.' + (video.canPlayType('video/ogg') ? 'ogv' : 'mp4'); |
video.addEventListener('canplaythrough', function() { |
if (window.testRunner) { |
- testRunner.display(); |
- testRunner.setPageVisibility("hidden"); |
- testRunner.display(); |
- testRunner.notifyDone(); |
+ runAfterDisplay(function() { |
+ testRunner.setPageVisibility("hidden"); |
+ testRunner.notifyDone(); |
+ }); |
} |
}, false); |
</script> |