Commit 680764f1 authored by rockot's avatar rockot Committed by Commit bot

Revert of [Cast, Tests] Handle low end and JB devices that don't preload...

Revert of [Cast, Tests] Handle low end and JB devices that don't preload videos (patchset #1 id:1 of https://codereview.chromium.org/2400543002/ )

Reason for revert:
Speculative revert because cast tests started flaking very heavily at this revision and it's effectively blocking things in the CQ.

See https://build.chromium.org/p/tryserver.chromium.android/builders/linux_android_rel_ng?numbuilds=200 for example failures

Original issue's description:
> [Cast, Tests] Handle low end and JB devices that don't preload videos
>
> BUG=652872,652389
> TEST=run_chrome_public_test_apk --verbose --gtest_filter=org.chromium.chrome.browser.media.remote.* on both low end and not a low end device.
>
> Since https://codereview.chromium.org/2344353003 on low-end and JB devices videos
> are not preloaded so we have to trigger that in a button onclick handler.
>
> Committed: https://crrev.com/6e5b06e0201d483a1596aedf438fb931fbbe7b42
> Cr-Commit-Position: refs/heads/master@{#423775}

TBR=mlamouri@chromium.org,avayvod@chromium.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=652872,652389

Review-Url: https://codereview.chromium.org/2394273003
Cr-Commit-Position: refs/heads/master@{#423799}
parent ca145c8a
...@@ -159,7 +159,6 @@ public class CastSwitchVideoTest extends CastTestBase { ...@@ -159,7 +159,6 @@ public class CastSwitchVideoTest extends CastTestBase {
TimeoutException { TimeoutException {
final Tab tab = getActivity().getActivityTab(); final Tab tab = getActivity().getActivityTab();
WebContents webContents = tab.getWebContents(); WebContents webContents = tab.getWebContents();
DOMUtils.clickNode(this, tab.getContentViewCore(), "button1");
waitUntilVideoReady(videoElement, webContents); waitUntilVideoReady(videoElement, webContents);
Rect videoRect = DOMUtils.getNodeBounds(webContents, videoElement); Rect videoRect = DOMUtils.getNodeBounds(webContents, videoElement);
...@@ -171,7 +170,6 @@ public class CastSwitchVideoTest extends CastTestBase { ...@@ -171,7 +170,6 @@ public class CastSwitchVideoTest extends CastTestBase {
final Tab tab = getActivity().getActivityTab(); final Tab tab = getActivity().getActivityTab();
WebContents webContents = tab.getWebContents(); WebContents webContents = tab.getWebContents();
DOMUtils.clickNode(this, tab.getContentViewCore(), "button1");
waitUntilVideoReady(videoElement, webContents); waitUntilVideoReady(videoElement, webContents);
// Need to click on the video first to overcome the user gesture requirement. // Need to click on the video first to overcome the user gesture requirement.
......
...@@ -262,7 +262,6 @@ public abstract class CastTestBase extends ChromeActivityTestCaseBase<ChromeActi ...@@ -262,7 +262,6 @@ public abstract class CastTestBase extends ChromeActivityTestCaseBase<ChromeActi
WebContents webContents = currentTab.getWebContents(); WebContents webContents = currentTab.getWebContents();
DOMUtils.clickNode(this, currentTab.getContentViewCore(), "button1");
waitUntilVideoReady(VIDEO_ELEMENT, webContents); waitUntilVideoReady(VIDEO_ELEMENT, webContents);
return DOMUtils.getNodeBounds(webContents, VIDEO_ELEMENT); return DOMUtils.getNodeBounds(webContents, VIDEO_ELEMENT);
......
...@@ -4,12 +4,5 @@ ...@@ -4,12 +4,5 @@
<!-- Width should be large enough to dispaly all media controls without needing <!-- Width should be large enough to dispaly all media controls without needing
an overflow menu. --> an overflow menu. -->
<video src="test.webm" controls id="video" width=500></video> <video src="test.webm" controls id="video" width=500></video>
<script>
function loadvideo() {
var video = document.getElementById('video');
video.load();
}
</script>
<button id="button1" onclick="loadvideo()">Click me</button>
</body> </body>
</html> </html>
...@@ -2,12 +2,5 @@ ...@@ -2,12 +2,5 @@
<title>test</title> <title>test</title>
<body bgcolor="Silver"> <body bgcolor="Silver">
<video src="test2.webm" controls id="video"></video> <video src="test2.webm" controls id="video"></video>
<script>
function loadvideo() {
var video = document.getElementById('video');
video.load();
}
</script>
<button id="button1" onclick="loadvideo()">Click me</button>
</body> </body>
</html> </html>
...@@ -3,14 +3,5 @@ ...@@ -3,14 +3,5 @@
<body bgcolor="Silver"> <body bgcolor="Silver">
<video src="test.webm" controls id="video"></video> <video src="test.webm" controls id="video"></video>
<video src="test2.webm" controls id="video2"></video> <video src="test2.webm" controls id="video2"></video>
<script>
function loadvideos() {
var video = document.getElementById('video');
var video2 = document.getElementById('video2');
video.load();
video2.load();
}
</script>
<button id="button1" onclick="loadvideos()">Click me</button>
</body> </body>
</html> </html>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment