| Index: chrome/android/javatests/src/org/chromium/chrome/browser/services/GoogleServicesManagerIntegrationTest.java
|
| diff --git a/chrome/android/javatests/src/org/chromium/chrome/browser/services/GoogleServicesManagerIntegrationTest.java b/chrome/android/javatests/src/org/chromium/chrome/browser/services/GoogleServicesManagerIntegrationTest.java
|
| index b73c7777bc6feb353feb8425e406527ff7f1c2d7..9ebae05725ba4e02637060729f6e81dc887289c2 100644
|
| --- a/chrome/android/javatests/src/org/chromium/chrome/browser/services/GoogleServicesManagerIntegrationTest.java
|
| +++ b/chrome/android/javatests/src/org/chromium/chrome/browser/services/GoogleServicesManagerIntegrationTest.java
|
| @@ -4,35 +4,45 @@
|
|
|
| package org.chromium.chrome.browser.services;
|
|
|
| -import android.test.UiThreadTest;
|
| +import android.support.test.annotation.UiThreadTest;
|
|
|
| +import org.junit.Before;
|
| +import org.junit.Rule;
|
| +import org.junit.Test;
|
| +import org.junit.runner.RunWith;
|
| +
|
| +import org.chromium.base.test.util.CommandLineFlags;
|
| import org.chromium.base.test.util.DisabledTest;
|
| import org.chromium.chrome.browser.ChromeActivity;
|
| -import org.chromium.chrome.test.ChromeActivityTestCaseBase;
|
| +import org.chromium.chrome.browser.ChromeSwitches;
|
| +import org.chromium.chrome.test.ChromeActivityTestRule;
|
| +import org.chromium.chrome.test.ChromeJUnit4ClassRunner;
|
|
|
| /**
|
| * Google Services Manager tests
|
| */
|
| -public class GoogleServicesManagerIntegrationTest
|
| - extends ChromeActivityTestCaseBase<ChromeActivity> {
|
| -
|
| - public GoogleServicesManagerIntegrationTest() {
|
| - super(ChromeActivity.class);
|
| - }
|
| +@RunWith(ChromeJUnit4ClassRunner.class)
|
| +@CommandLineFlags.Add({ChromeSwitches.DISABLE_FIRST_RUN_EXPERIENCE,
|
| + ChromeActivityTestRule.DISABLE_NETWORK_PREDICTION_FLAG})
|
| +public class GoogleServicesManagerIntegrationTest {
|
| + @Rule
|
| + public ChromeActivityTestRule<ChromeActivity> mActivityTestRule =
|
| + new ChromeActivityTestRule<>(ChromeActivity.class);
|
|
|
| /**
|
| * Test changing the state of auto login
|
| * @SmallTest
|
| * @Feature({"Sync", "Main"})
|
| */
|
| + @Test
|
| @DisabledTest(message = "crbug.com/413289")
|
| @UiThreadTest
|
| public void testSetAutologinState() {
|
| // TODO(acleung): Add back some sort of test for the GSM.
|
| }
|
|
|
| - @Override
|
| - public void startMainActivity() throws InterruptedException {
|
| - startMainActivityOnBlankPage();
|
| + @Before
|
| + public void setUp() throws InterruptedException {
|
| + mActivityTestRule.startMainActivityOnBlankPage();
|
| }
|
| }
|
|
|