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

Unified Diff: chrome/android/javatests/src/org/chromium/chrome/browser/customtabs/CustomTabActivityTestBase.java

Issue 1267243003: Add custom tabs tests using intents with non-null sessions (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added the utils class Created 5 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
Index: chrome/android/javatests/src/org/chromium/chrome/browser/customtabs/CustomTabActivityTestBase.java
diff --git a/chrome/android/javatests/src/org/chromium/chrome/browser/customtabs/CustomTabActivityTestBase.java b/chrome/android/javatests/src/org/chromium/chrome/browser/customtabs/CustomTabActivityTestBase.java
index 8744564e206908f7f221688f85e8f5180ee18464..41f9a6c718a80beb8449d9e4fe14f493df500c72 100644
--- a/chrome/android/javatests/src/org/chromium/chrome/browser/customtabs/CustomTabActivityTestBase.java
+++ b/chrome/android/javatests/src/org/chromium/chrome/browser/customtabs/CustomTabActivityTestBase.java
@@ -6,15 +6,10 @@ package org.chromium.chrome.browser.customtabs;
import android.app.Activity;
import android.app.Instrumentation;
-import android.content.ComponentName;
import android.content.Intent;
-import android.net.Uri;
-import android.support.customtabs.CustomTabsIntent;
import org.chromium.chrome.browser.DeferredStartupHandler;
-import org.chromium.chrome.browser.document.ChromeLauncherActivity;
import org.chromium.chrome.browser.tab.Tab;
-import org.chromium.chrome.browser.util.IntentUtils;
import org.chromium.chrome.test.ChromeActivityTestCaseBase;
import org.chromium.content.browser.test.util.Criteria;
import org.chromium.content.browser.test.util.CriteriaHelper;
@@ -67,22 +62,9 @@ public abstract class CustomTabActivityTestBase extends
public boolean isSatisfied() {
return DeferredStartupHandler.getInstance().isDeferredStartupComplete();
}
- }));
+ }, 5000, 200));
assertNotNull(tab);
assertNotNull(tab.getView());
}
-
- /**
- * Creates the simplest intent that is sufficient to let {@link ChromeLauncherActivity} launch
- * the {@link CustomTabActivity}.
- */
- protected Intent createMinimalCustomTabIntent(String url) {
- Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(url));
- intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
- intent.setComponent(new ComponentName(getInstrumentation().getTargetContext(),
- ChromeLauncherActivity.class));
- IntentUtils.safePutBinderExtra(intent, CustomTabsIntent.EXTRA_SESSION, null);
- return intent;
- }
}

Powered by Google App Engine
This is Rietveld 408576698