Index: content/public/test/browser_test_utils.cc |
diff --git a/content/public/test/browser_test_utils.cc b/content/public/test/browser_test_utils.cc |
index a19331b5cd02916d45148f003b4375307ba4e8cd..97d01375b729101504e08ea93fb80d5bd6df55b9 100644 |
--- a/content/public/test/browser_test_utils.cc |
+++ b/content/public/test/browser_test_utils.cc |
@@ -109,7 +109,7 @@ bool ExecuteScriptHelper(RenderFrameHost* render_frame_host, |
std::string script = |
"window.domAutomationController.setAutomationId(0);" + original_script; |
DOMOperationObserver dom_op_observer(render_frame_host->GetRenderViewHost()); |
- render_frame_host->ExecuteJavaScript(base::UTF8ToUTF16(script)); |
+ render_frame_host->ExecuteJavaScriptForTests(base::UTF8ToUTF16(script)); |
std::string json; |
if (!dom_op_observer.WaitAndGetResponse(&json)) { |
DLOG(ERROR) << "Cannot communicate with DOMOperationObserver."; |