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

Unified Diff: content/public/test/android/javatests/src/org/chromium/content/browser/test/util/TestCallbackHelperContainer.java

Issue 11085008: [Android] Upstream content detection and ChromeBrowserProvider tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase after landing resources separately. Created 8 years, 2 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: content/public/test/android/javatests/src/org/chromium/content/browser/test/util/TestCallbackHelperContainer.java
diff --git a/content/public/test/android/javatests/src/org/chromium/content/browser/test/util/TestCallbackHelperContainer.java b/content/public/test/android/javatests/src/org/chromium/content/browser/test/util/TestCallbackHelperContainer.java
index 76ed610acbc3f07709a2a7165c70491e2a70f5a4..5d52a4fea64ec948415b2e7295b739f97b36f21f 100644
--- a/content/public/test/android/javatests/src/org/chromium/content/browser/test/util/TestCallbackHelperContainer.java
+++ b/content/public/test/android/javatests/src/org/chromium/content/browser/test/util/TestCallbackHelperContainer.java
@@ -10,7 +10,7 @@ import org.chromium.content.browser.ContentView;
/**
* This class is used to provide callback hooks for tests and related classes.
*/
-public class TestCallbackHelperContainer{
+public class TestCallbackHelperContainer {
private TestContentViewClient mTestContentViewClient;
private TestWebContentsObserver mTestWebContentsObserver;
@@ -86,6 +86,18 @@ public class TestCallbackHelperContainer{
}
}
+ public static class OnStartContentIntentHelper extends CallbackHelper {
+ private String mIntentUrl;
+ public void notifyCalled(String intentUrl) {
+ mIntentUrl = intentUrl;
+ notifyCalled();
+ }
+ public String getIntentUrl() {
+ assert getCallCount() > 0;
+ return mIntentUrl;
+ }
+ }
+
public OnPageStartedHelper getOnPageStartedHelper() {
return mTestWebContentsObserver.getOnPageStartedHelper();
}
@@ -101,4 +113,8 @@ public class TestCallbackHelperContainer{
public OnEvaluateJavaScriptResultHelper getOnEvaluateJavaScriptResultHelper() {
return mTestContentViewClient.getOnEvaluateJavaScriptResultHelper();
}
+
+ public OnStartContentIntentHelper getOnStartContentIntentHelper() {
+ return mTestContentViewClient.getOnStartContentIntentHelper();
+ }
}

Powered by Google App Engine
This is Rietveld 408576698