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

Unified Diff: content/shell/browser/layout_test/blink_test_controller.cc

Issue 1819243002: [DevTools] Use InspectorFrontendHost.readyForTest for layout tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ready-for-test
Patch Set: resource-tree-reload.html fix Created 4 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/browser/layout_test/blink_test_controller.cc
diff --git a/content/shell/browser/layout_test/blink_test_controller.cc b/content/shell/browser/layout_test/blink_test_controller.cc
index 87a286f6561e618e77b704948e068f374e2b95a5..2a5d083e015dc0a7c9d3435d6ca6c379f24b2155 100644
--- a/content/shell/browser/layout_test/blink_test_controller.cc
+++ b/content/shell/browser/layout_test/blink_test_controller.cc
@@ -413,6 +413,8 @@ bool BlinkTestController::OnMessageReceived(const IPC::Message& message) {
IPC_MESSAGE_HANDLER(ShellViewHostMsg_ClearDevToolsLocalStorage,
OnClearDevToolsLocalStorage)
IPC_MESSAGE_HANDLER(ShellViewHostMsg_ShowDevTools, OnShowDevTools)
+ IPC_MESSAGE_HANDLER(ShellViewHostMsg_EvaluateInDevTools,
+ OnEvaluateInDevTools)
IPC_MESSAGE_HANDLER(ShellViewHostMsg_CloseDevTools, OnCloseDevTools)
IPC_MESSAGE_HANDLER(ShellViewHostMsg_GoToOffset, OnGoToOffset)
IPC_MESSAGE_HANDLER(ShellViewHostMsg_Reload, OnReload)
@@ -766,6 +768,12 @@ void BlinkTestController::OnShowDevTools(const std::string& settings,
devtools_frontend_->Focus();
}
+void BlinkTestController::OnEvaluateInDevTools(
+ int call_id, const std::string& script) {
+ if (devtools_frontend_)
+ devtools_frontend_->EvaluateInFrontend(call_id, script);
+}
+
void BlinkTestController::OnCloseDevTools() {
if (devtools_frontend_)
devtools_frontend_->DisconnectFromTarget();

Powered by Google App Engine
This is Rietveld 408576698