Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2426)

Unified Diff: android_webview/javatests/src/org/chromium/android_webview/test/MultipleVideosTest.java

Issue 1131793004: Migrate AudioFocusChangeListener to browser and always send GAIN (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: webview suggestions from boliu Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: android_webview/javatests/src/org/chromium/android_webview/test/MultipleVideosTest.java
diff --git a/android_webview/javatests/src/org/chromium/android_webview/test/MultipleVideosTest.java b/android_webview/javatests/src/org/chromium/android_webview/test/MultipleVideosTest.java
index 8e55cd2630683b88371957d1eb642fc50ff55dfd..a3e91ccfb6c2f9cba3208e0b23468c0e9c8eafe2 100644
--- a/android_webview/javatests/src/org/chromium/android_webview/test/MultipleVideosTest.java
+++ b/android_webview/javatests/src/org/chromium/android_webview/test/MultipleVideosTest.java
@@ -57,7 +57,9 @@ public class MultipleVideosTest extends AwTestBase {
// Play the first video.
tapFirstPlayButton();
- assertTrue(DOMUtils.waitForVideoPlay(getWebContentsOnUiThread(), FIRST_VIDEO_ID));
+ assertTrue(DOMUtils.waitForVideoState(getWebContentsOnUiThread(),
+ FIRST_VIDEO_ID,
+ DOMUtils.VIDEO_STATE_PLAYING));
// Verify that there is one video hole surface.
VideoSurfaceViewUtils.pollAndAssertContainsOneVideoHoleSurfaceView(this,
@@ -65,7 +67,9 @@ public class MultipleVideosTest extends AwTestBase {
// Start the second video.
tapSecondPlayButton();
- assertTrue(DOMUtils.waitForVideoPlay(getWebContentsOnUiThread(), SECOND_VIDEO_ID));
+ assertTrue(DOMUtils.waitForVideoState(getWebContentsOnUiThread(),
+ SECOND_VIDEO_ID,
+ DOMUtils.VIDEO_STATE_PLAYING));
// Verify that the first video pauses once the second video starts.
assertFalse(DOMUtils.isVideoPaused(getWebContentsOnUiThread(), SECOND_VIDEO_ID));

Powered by Google App Engine
This is Rietveld 408576698