Work around a crash when running media/modern-media-controls/pip-support/pip-support...
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 25 Jan 2017 02:56:40 +0000 (02:56 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 25 Jan 2017 02:56:40 +0000 (02:56 +0000)
https://bugs.webkit.org/show_bug.cgi?id=167381

Patch by Antoine Quint <graouts@apple.com> on 2017-01-24
Reviewed by Dean Jackson.

The test at media/modern-media-controls/pip-support/pip-support-enabled.html would crash because the test that
preceded it, media/modern-media-controls/pip-support/pip-support-click.html, would not exit the PiP presentation mode
before exiting the test. We now exit PiP before proceeding to the next test which avoid hitting the assertion
and the crash in Debug builds.

* media/modern-media-controls/pip-support/pip-support-click.html:
* platform/mac-wk1/TestExpectations:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@211130 268f45cc-cd09-0410-ab3c-d52691b4dbfc

LayoutTests/ChangeLog
LayoutTests/media/modern-media-controls/pip-support/pip-support-click.html
LayoutTests/platform/mac-wk1/TestExpectations

index eb98806..ef0326d 100644 (file)
@@ -1,3 +1,18 @@
+2017-01-24  Antoine Quint  <graouts@apple.com>
+
+        Work around a crash when running media/modern-media-controls/pip-support/pip-support-enabled.html
+        https://bugs.webkit.org/show_bug.cgi?id=167381
+
+        Reviewed by Dean Jackson.
+
+        The test at media/modern-media-controls/pip-support/pip-support-enabled.html would crash because the test that
+        preceded it, media/modern-media-controls/pip-support/pip-support-click.html, would not exit the PiP presentation mode
+        before exiting the test. We now exit PiP before proceeding to the next test which avoid hitting the assertion
+        and the crash in Debug builds.
+
+        * media/modern-media-controls/pip-support/pip-support-click.html:
+        * platform/mac-wk1/TestExpectations:
+
 2017-01-24  Brent Fulgham  <bfulgham@apple.com>
 
         Bug 167392: REGRESSION(r210531): Relax same-volume display requirement for iOS
index f69338e..2598470 100644 (file)
@@ -24,8 +24,6 @@ window.jsTestIsAsync = true;
 
 description("Testing the <code>PiPSupport</code> behavior when clicking the PiP button.");
 
-iconService.directoryPath = "../../../../Source/WebCore/Modules/modern-media-controls/images";
-
 if (window.internals)
     window.internals.settings.setAllowsPictureInPictureMediaPlayback(true);
 
@@ -48,6 +46,11 @@ scheduler.frameDidFire = function() {
 
 media.addEventListener("webkitpresentationmodechanged", () => {
     shouldBeEqualToString("media.webkitPresentationMode", "picture-in-picture");
+
+    // FIXME: We exit PiP so we leave things in a clean state, otherwise the following
+    // test pip-support-enabled.html may crash, see webkit.org/b/164336.
+    media.webkitSetPresentationMode("inline");
+
     container.remove();
     media.remove();
     finishMediaControlsTest();
index 98a1cff..2223490 100644 (file)
@@ -301,8 +301,6 @@ media/modern-media-controls/tracks-support/tracks-support-click-track-in-panel.h
 
 webkit.org/b/167253 media/modern-media-controls/macos-fullscreen-media-controls/macos-fullscreen-media-controls-buttons-containers-styles.html [ Pass Failure ]
 
-webkit.org/b/164336 [ Sierra Debug ] media/modern-media-controls/pip-support/pip-support-enabled.html [ Crash ]
-
 webkit.org/b/167320 [ Sierra Release ] media/modern-media-controls/placard-support/placard-support-pip.html [ Pass Crash ]
 
 webkit.org/b/167352 [ ElCapitan Debug ] media/modern-media-controls/rewind-button/rewind-button.html [ Pass Timeout ]