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

Unified Diff: chrome/android/javatests/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManagerTest.java

Issue 2204983002: [TTS] Update instrumentation tests to work with Tap Suppression. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed a reference to the obsolete testing flag in ContextualSearchFieldTrial. Created 4 years, 4 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
« no previous file with comments | « chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchFieldTrial.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/javatests/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManagerTest.java
diff --git a/chrome/android/javatests/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManagerTest.java b/chrome/android/javatests/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManagerTest.java
index 41912fec05d2ecbcd03f826369b574737e29aeac..7718d1a9d0653b28df8632fb3438a7073a587332 100644
--- a/chrome/android/javatests/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManagerTest.java
+++ b/chrome/android/javatests/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManagerTest.java
@@ -31,7 +31,6 @@ import org.chromium.base.test.util.FlakyTest;
import org.chromium.base.test.util.Restriction;
import org.chromium.chrome.R;
import org.chromium.chrome.browser.ChromeActivity;
-import org.chromium.chrome.browser.ChromeSwitches;
import org.chromium.chrome.browser.ChromeTabbedActivity;
import org.chromium.chrome.browser.compositor.bottombar.OverlayContentDelegate;
import org.chromium.chrome.browser.compositor.bottombar.OverlayContentProgressObserver;
@@ -77,13 +76,13 @@ import java.util.concurrent.TimeoutException;
/**
* Tests the Contextual Search Manager using instrumentation tests.
*/
-@CommandLineFlags.Add(ChromeSwitches.ENABLE_CONTEXTUAL_SEARCH_FOR_TESTING)
public class ContextualSearchManagerTest extends ChromeActivityTestCaseBase<ChromeActivity> {
private static final String TEST_PAGE =
"/chrome/test/data/android/contextualsearch/tap_test.html";
private static final int TEST_TIMEOUT = 15000;
private static final int TEST_EXPECTED_FAILURE_TIMEOUT = 1000;
+ private static final int PLENTY_OF_TAPS = 1000;
// TODO(donnd): get these from TemplateURL once the low-priority or Contextual Search API
// is fully supported.
@@ -1975,9 +1974,10 @@ public class ContextualSearchManagerTest extends ChromeActivityTestCaseBase<Chro
@SmallTest
@Feature({"ContextualSearch"})
@Restriction(RESTRICTION_TYPE_NON_LOW_END_DEVICE)
+ @CommandLineFlags.Add(ContextualSearchFieldTrial.SUPPRESSION_TAPS + "=" + PLENTY_OF_TAPS)
public void testTapALot() throws InterruptedException, TimeoutException {
- mPolicy.setTapLimitForDecidedForTesting(200);
- mPolicy.setTapLimitForUndecidedForTesting(200);
+ mPolicy.setTapLimitForDecidedForTesting(PLENTY_OF_TAPS);
+ mPolicy.setTapLimitForUndecidedForTesting(PLENTY_OF_TAPS);
for (int i = 0; i < 50; i++) {
clickToTriggerPrefetch();
waitForSelectionDissolved();
« no previous file with comments | « chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchFieldTrial.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698