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

Unified Diff: content/shell/renderer/test_runner/TestRunner.cpp

Issue 200663002: Add 'waitUntilExternalURLLoad' method to TestRunner. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 9 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/shell/renderer/test_runner/TestRunner.cpp
diff --git a/content/shell/renderer/test_runner/TestRunner.cpp b/content/shell/renderer/test_runner/TestRunner.cpp
index 2584a3b3572ac1cfb27a78ac8add5d99403eae5a..f1a2c4223044e7a5664611a4f2fa0d38f21360ce 100644
--- a/content/shell/renderer/test_runner/TestRunner.cpp
+++ b/content/shell/renderer/test_runner/TestRunner.cpp
@@ -280,6 +280,7 @@ TestRunner::TestRunner(TestInterfaces* interfaces)
bindMethod("setWillSendRequestClearHeader", &TestRunner::setWillSendRequestClearHeader);
bindMethod("dumpResourceRequestPriorities", &TestRunner::dumpResourceRequestPriorities);
bindMethod("setUseMockTheme", &TestRunner::setUseMockTheme);
+ bindMethod("waitUntilExternalURLLoad", &TestRunner::waitUntilExternalURLLoad);
// The following methods interact with the WebTestProxy.
// The following methods interact with the WebTestDelegate.
@@ -439,6 +440,7 @@ void TestRunner::reset()
m_midiAccessorResult = true;
m_shouldStayOnPageAfterHandlingBeforeUnload = false;
m_shouldDumpResourcePriorities = false;
+ m_shouldWaitUntilExternalURLLoad = false;
m_httpHeadersToClear.clear();
@@ -711,6 +713,11 @@ bool TestRunner::shouldDumpResourcePriorities() const
return m_shouldDumpResourcePriorities;
}
+bool TestRunner::shouldWaitUntilExternURLLoad() const
+{
+ return m_shouldWaitUntilExternalURLLoad;
+}
+
WebNotificationPresenter* TestRunner::notification_presenter() const
{
return notification_presenter_.get();
@@ -1487,6 +1494,12 @@ void TestRunner::setUseMockTheme(const CppArgumentList& arguments, CppVariant* r
m_useMockTheme = arguments.size() < 1 || arguments[0].toBoolean();
}
+void TestRunner::waitUntilExternalURLLoad(const CppArgumentList& arguments, CppVariant* result)
+{
+ result->setNull();
+ m_shouldWaitUntilExternalURLLoad = true;
+}
+
void TestRunner::useUnfortunateSynchronousResizeMode(const CppArgumentList& arguments, CppVariant* result)
{
result->setNull();

Powered by Google App Engine
This is Rietveld 408576698