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

Unified Diff: chrome/android/javatests/src/org/chromium/chrome/browser/translate/TranslateInfoBarTest.java

Issue 1582513003: Add a testing restriction for whether Google Play Services is up-to-date. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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: chrome/android/javatests/src/org/chromium/chrome/browser/translate/TranslateInfoBarTest.java
diff --git a/chrome/android/javatests/src/org/chromium/chrome/browser/translate/TranslateInfoBarTest.java b/chrome/android/javatests/src/org/chromium/chrome/browser/translate/TranslateInfoBarTest.java
index 7e68c43579e049a55e9c0d31c6311677eaeaf1e0..11e0d85dd9b493bdc770569667177d198c4bff0c 100644
--- a/chrome/android/javatests/src/org/chromium/chrome/browser/translate/TranslateInfoBarTest.java
+++ b/chrome/android/javatests/src/org/chromium/chrome/browser/translate/TranslateInfoBarTest.java
@@ -4,7 +4,10 @@
package org.chromium.chrome.browser.translate;
-import org.chromium.base.test.util.DisabledTest;
+import android.test.suitebuilder.annotation.MediumTest;
+
+import org.chromium.base.test.util.Feature;
+import org.chromium.base.test.util.Restriction;
import org.chromium.chrome.browser.ChromeActivity;
import org.chromium.chrome.browser.infobar.InfoBar;
import org.chromium.chrome.browser.infobar.InfoBarContainer;
@@ -18,8 +21,6 @@ import org.chromium.chrome.test.util.TranslateUtil;
* Tests for the translate infobar, assumes it runs on a system with language
* preferences set to English.
*
- * Note: these tests all currently fail because they depend on a newer version of Google Play
- * Services than is installed on the test devices. See http://crbug.com/514449
*/
public class TranslateInfoBarTest extends ChromeActivityTestCaseBase<ChromeActivity> {
@@ -50,12 +51,10 @@ public class TranslateInfoBarTest extends ChromeActivityTestCaseBase<ChromeActiv
/**
* Test the translate language panel.
- *
- * Bug http://crbug.com/514449
- * @MediumTest
- * @Feature({"Browser", "Main"})
*/
- @DisabledTest
+ @MediumTest
+ @Feature({"Browser", "Main"})
+ @Restriction({Restriction.RESTRICTION_TYPE_GOOGLE_PLAY_SERVICES})
public void testTranslateLanguagePanel() throws InterruptedException {
loadUrl(TestHttpServerClient.getUrl(TRANSLATE_PAGE));
assertTrue("InfoBar not opened.", mListener.addInfoBarAnimationFinished());
@@ -67,12 +66,10 @@ public class TranslateInfoBarTest extends ChromeActivityTestCaseBase<ChromeActiv
/**
* Test the "never translate" panel.
- *
- * Bug http://crbug.com/514449
- * @MediumTest
- * @Feature({"Browser", "Main"})
*/
- @DisabledTest
+ @MediumTest
+ @Feature({"Browser", "Main"})
+ @Restriction({Restriction.RESTRICTION_TYPE_GOOGLE_PLAY_SERVICES})
public void testTranslateNeverPanel() throws InterruptedException {
loadUrl(TestHttpServerClient.getUrl(TRANSLATE_PAGE));
assertTrue("InfoBar not opened.", mListener.addInfoBarAnimationFinished());
@@ -93,12 +90,10 @@ public class TranslateInfoBarTest extends ChromeActivityTestCaseBase<ChromeActiv
/**
* Test infobar transitions.
- *
- * Bug http://crbug.com/514449
- * @MediumTest
- * @Feature({"Browser", "Main"})
*/
- @DisabledTest
+ @MediumTest
+ @Feature({"Browser", "Main"})
+ @Restriction({Restriction.RESTRICTION_TYPE_GOOGLE_PLAY_SERVICES})
public void testTranslateTransitions() throws InterruptedException {
loadUrl(TestHttpServerClient.getUrl(TRANSLATE_PAGE));
assertTrue("InfoBar not Added", mListener.addInfoBarAnimationFinished());

Powered by Google App Engine
This is Rietveld 408576698