diff options
Diffstat (limited to 'chrome/test/chromedriver')
19 files changed, 73 insertions, 58 deletions
diff --git a/chrome/test/chromedriver/capabilities_unittest.cc b/chrome/test/chromedriver/capabilities_unittest.cc index f6ac5ec..9bf6c32 100644 --- a/chrome/test/chromedriver/capabilities_unittest.cc +++ b/chrome/test/chromedriver/capabilities_unittest.cc @@ -21,7 +21,7 @@ TEST(ParseCapabilities, WithAndroidPackage) { TEST(ParseCapabilities, EmptyAndroidPackage) { Capabilities capabilities; base::DictionaryValue caps; - caps.SetString("chromeOptions.android_package", ""); + caps.SetString("chromeOptions.android_package", std::string()); Status status = capabilities.Parse(caps); ASSERT_FALSE(status.IsOk()); } diff --git a/chrome/test/chromedriver/chrome/automation_extension.cc b/chrome/test/chromedriver/chrome/automation_extension.cc index 0a91cf5..63ad223 100644 --- a/chrome/test/chromedriver/chrome/automation_extension.cc +++ b/chrome/test/chromedriver/chrome/automation_extension.cc @@ -52,8 +52,11 @@ Status AutomationExtension::GetWindowInfo(int* x, int* height) { base::ListValue args; scoped_ptr<base::Value> result; - Status status = web_view_->CallAsyncFunction( - "", "getWindowInfo", args, base::TimeDelta::FromSeconds(10), &result); + Status status = web_view_->CallAsyncFunction(std::string(), + "getWindowInfo", + args, + base::TimeDelta::FromSeconds(10), + &result); if (status.IsError()) return status; @@ -78,6 +81,9 @@ Status AutomationExtension::UpdateWindow( base::ListValue args; args.Append(update_info.DeepCopy()); scoped_ptr<base::Value> result; - return web_view_->CallAsyncFunction( - "", "updateWindow", args, base::TimeDelta::FromSeconds(10), &result); + return web_view_->CallAsyncFunction(std::string(), + "updateWindow", + args, + base::TimeDelta::FromSeconds(10), + &result); } diff --git a/chrome/test/chromedriver/chrome/chrome_desktop_impl.cc b/chrome/test/chromedriver/chrome/chrome_desktop_impl.cc index bee5bd2..49dfad2 100644 --- a/chrome/test/chromedriver/chrome/chrome_desktop_impl.cc +++ b/chrome/test/chromedriver/chrome/chrome_desktop_impl.cc @@ -67,7 +67,7 @@ Status ChromeDesktopImpl::GetAutomationExtension( return status; // Wait for the extension background page to load. - status = web_view->WaitForPendingNavigations(""); + status = web_view->WaitForPendingNavigations(std::string()); if (status.IsError()) return status; diff --git a/chrome/test/chromedriver/chrome/devtools_http_client.cc b/chrome/test/chromedriver/chrome/devtools_http_client.cc index c0fc841..3cfcdae 100644 --- a/chrome/test/chromedriver/chrome/devtools_http_client.cc +++ b/chrome/test/chromedriver/chrome/devtools_http_client.cc @@ -169,7 +169,8 @@ Status DevToolsHttpClient::CloseFrontends(const std::string& for_client_id) { scoped_ptr<base::Value> result; status = web_view->EvaluateScript( - "", "document.querySelector('*[id^=\"close-button-\"').click();", + std::string(), + "document.querySelector('*[id^=\"close-button-\"').click();", &result); // Ignore disconnected error, because it may be closed already. if (status.IsError() && status.code() != kDisconnected) diff --git a/chrome/test/chromedriver/chrome/devtools_http_client_unittest.cc b/chrome/test/chromedriver/chrome/devtools_http_client_unittest.cc index eff9b3f..c92abb8 100644 --- a/chrome/test/chromedriver/chrome/devtools_http_client_unittest.cc +++ b/chrome/test/chromedriver/chrome/devtools_http_client_unittest.cc @@ -64,8 +64,7 @@ TEST(ParseWebViewsInfo, WithoutDebuggerUrl) { ASSERT_TRUE(status.IsOk()); ASSERT_EQ(1u, views_info.GetSize()); ExpectEqual( - WebViewInfo( - "1", "", "http://page1", WebViewInfo::kPage), + WebViewInfo("1", std::string(), "http://page1", WebViewInfo::kPage), views_info.Get(0)); } diff --git a/chrome/test/chromedriver/chrome/javascript_dialog_manager_unittest.cc b/chrome/test/chromedriver/chrome/javascript_dialog_manager_unittest.cc index fcc3dce..1333090 100644 --- a/chrome/test/chromedriver/chrome/javascript_dialog_manager_unittest.cc +++ b/chrome/test/chromedriver/chrome/javascript_dialog_manager_unittest.cc @@ -19,7 +19,7 @@ TEST(JavaScriptDialogManager, NoDialog) { ASSERT_EQ(kNoAlertOpen, manager.GetDialogMessage(&message).code()); ASSERT_FALSE(manager.IsDialogOpen()); ASSERT_STREQ("HI", message.c_str()); - ASSERT_EQ(kNoAlertOpen, manager.HandleDialog(false, "").code()); + ASSERT_EQ(kNoAlertOpen, manager.HandleDialog(false, std::string()).code()); } namespace { @@ -73,7 +73,7 @@ TEST(JavaScriptDialogManager, ReconnectClearsStateAndSendsEnable) { ASSERT_EQ("Page.enable", client.method_); ASSERT_FALSE(manager.IsDialogOpen()); ASSERT_EQ(kNoAlertOpen, manager.GetDialogMessage(&message).code()); - ASSERT_EQ(kNoAlertOpen, manager.HandleDialog(false, "").code()); + ASSERT_EQ(kNoAlertOpen, manager.HandleDialog(false, std::string()).code()); } namespace { @@ -125,10 +125,10 @@ TEST(JavaScriptDialogManager, OneDialog) { ASSERT_EQ("hi", message); client.set_closing_count(1); - ASSERT_EQ(kOk, manager.HandleDialog(false, "").code()); + ASSERT_EQ(kOk, manager.HandleDialog(false, std::string()).code()); ASSERT_FALSE(manager.IsDialogOpen()); ASSERT_EQ(kNoAlertOpen, manager.GetDialogMessage(&message).code()); - ASSERT_EQ(kNoAlertOpen, manager.HandleDialog(false, "").code()); + ASSERT_EQ(kNoAlertOpen, manager.HandleDialog(false, std::string()).code()); } TEST(JavaScriptDialogManager, TwoDialogs) { @@ -145,16 +145,16 @@ TEST(JavaScriptDialogManager, TwoDialogs) { ASSERT_TRUE(manager.IsDialogOpen()); ASSERT_EQ("1", message); - ASSERT_EQ(kOk, manager.HandleDialog(false, "").code()); + ASSERT_EQ(kOk, manager.HandleDialog(false, std::string()).code()); ASSERT_TRUE(manager.IsDialogOpen()); ASSERT_EQ(kOk, manager.GetDialogMessage(&message).code()); ASSERT_EQ("2", message); client.set_closing_count(2); - ASSERT_EQ(kOk, manager.HandleDialog(false, "").code()); + ASSERT_EQ(kOk, manager.HandleDialog(false, std::string()).code()); ASSERT_FALSE(manager.IsDialogOpen()); ASSERT_EQ(kNoAlertOpen, manager.GetDialogMessage(&message).code()); - ASSERT_EQ(kNoAlertOpen, manager.HandleDialog(false, "").code()); + ASSERT_EQ(kNoAlertOpen, manager.HandleDialog(false, std::string()).code()); } TEST(JavaScriptDialogManager, OneDialogManualClose) { @@ -174,5 +174,5 @@ TEST(JavaScriptDialogManager, OneDialogManualClose) { manager.OnEvent("Page.javascriptDialogClosing", params); ASSERT_FALSE(manager.IsDialogOpen()); ASSERT_EQ(kNoAlertOpen, manager.GetDialogMessage(&message).code()); - ASSERT_EQ(kNoAlertOpen, manager.HandleDialog(false, "").code()); + ASSERT_EQ(kNoAlertOpen, manager.HandleDialog(false, std::string()).code()); } diff --git a/chrome/test/chromedriver/chrome/navigation_tracker_unittest.cc b/chrome/test/chromedriver/chrome/navigation_tracker_unittest.cc index 79cc0f6..19a78ef3 100644 --- a/chrome/test/chromedriver/chrome/navigation_tracker_unittest.cc +++ b/chrome/test/chromedriver/chrome/navigation_tracker_unittest.cc @@ -173,7 +173,7 @@ class DeterminingLoadStateDevToolsClient : public StubDevToolsClient { TEST(NavigationTracker, UnknownStateForcesStart) { base::DictionaryValue params; - DeterminingLoadStateDevToolsClient client(true, "", ¶ms); + DeterminingLoadStateDevToolsClient client(true, std::string(), ¶ms); NavigationTracker tracker(&client); ASSERT_NO_FATAL_FAILURE(AssertPendingState(&tracker, "f", true)); } diff --git a/chrome/test/chromedriver/chrome/stub_chrome.cc b/chrome/test/chromedriver/chrome/stub_chrome.cc index 39888a8..d990d4e 100644 --- a/chrome/test/chromedriver/chrome/stub_chrome.cc +++ b/chrome/test/chromedriver/chrome/stub_chrome.cc @@ -11,7 +11,7 @@ StubChrome::StubChrome() {} StubChrome::~StubChrome() {} std::string StubChrome::GetVersion() { - return ""; + return std::string(); } int StubChrome::GetBuildNo() { @@ -49,7 +49,7 @@ Status StubChrome::GetAutomationExtension(AutomationExtension** extension) { } std::string StubChrome::GetOperatingSystemName() { - return ""; + return std::string(); } Status StubChrome::Quit() { diff --git a/chrome/test/chromedriver/chrome/web_view_impl_unittest.cc b/chrome/test/chromedriver/chrome/web_view_impl_unittest.cc index 37e3284..ecdc85b 100644 --- a/chrome/test/chromedriver/chrome/web_view_impl_unittest.cc +++ b/chrome/test/chromedriver/chrome/web_view_impl_unittest.cc @@ -60,8 +60,8 @@ void AssertEvalFails(const base::DictionaryValue& command_result) { scoped_ptr<base::DictionaryValue> result; FakeDevToolsClient client; client.set_result(command_result); - Status status = internal::EvaluateScript(&client, 0, "", - internal::ReturnByValue, &result); + Status status = internal::EvaluateScript( + &client, 0, std::string(), internal::ReturnByValue, &result); ASSERT_EQ(kUnknownError, status.code()); ASSERT_FALSE(result); } @@ -72,8 +72,8 @@ TEST(EvaluateScript, CommandError) { scoped_ptr<base::DictionaryValue> result; FakeDevToolsClient client; client.set_status(Status(kUnknownError)); - Status status = internal::EvaluateScript(&client, 0, "", - internal::ReturnByValue, &result); + Status status = internal::EvaluateScript( + &client, 0, std::string(), internal::ReturnByValue, &result); ASSERT_EQ(kUnknownError, status.code()); ASSERT_FALSE(result); } @@ -104,7 +104,7 @@ TEST(EvaluateScript, Ok) { FakeDevToolsClient client; client.set_result(dict); ASSERT_TRUE(internal::EvaluateScript( - &client, 0, "", internal::ReturnByValue, &result).IsOk()); + &client, 0, std::string(), internal::ReturnByValue, &result).IsOk()); ASSERT_TRUE(result); ASSERT_TRUE(result->HasKey("key")); } @@ -117,7 +117,7 @@ TEST(EvaluateScriptAndGetValue, MissingType) { dict.SetInteger("result.value", 1); client.set_result(dict); ASSERT_TRUE(internal::EvaluateScriptAndGetValue( - &client, 0, "", &result).IsError()); + &client, 0, std::string(), &result).IsError()); } TEST(EvaluateScriptAndGetValue, Undefined) { @@ -127,8 +127,8 @@ TEST(EvaluateScriptAndGetValue, Undefined) { dict.SetBoolean("wasThrown", false); dict.SetString("result.type", "undefined"); client.set_result(dict); - Status status = internal::EvaluateScriptAndGetValue( - &client, 0, "", &result); + Status status = + internal::EvaluateScriptAndGetValue(&client, 0, std::string(), &result); ASSERT_EQ(kOk, status.code()); ASSERT_TRUE(result && result->IsType(base::Value::TYPE_NULL)); } @@ -141,8 +141,8 @@ TEST(EvaluateScriptAndGetValue, Ok) { dict.SetString("result.type", "integer"); dict.SetInteger("result.value", 1); client.set_result(dict); - Status status = internal::EvaluateScriptAndGetValue( - &client, 0, "", &result); + Status status = + internal::EvaluateScriptAndGetValue(&client, 0, std::string(), &result); ASSERT_EQ(kOk, status.code()); int value; ASSERT_TRUE(result && result->GetAsInteger(&value)); @@ -158,7 +158,7 @@ TEST(EvaluateScriptAndGetObject, NoObject) { bool got_object; std::string object_id; ASSERT_TRUE(internal::EvaluateScriptAndGetObject( - &client, 0, "", &got_object, &object_id).IsOk()); + &client, 0, std::string(), &got_object, &object_id).IsOk()); ASSERT_FALSE(got_object); ASSERT_TRUE(object_id.empty()); } @@ -172,7 +172,7 @@ TEST(EvaluateScriptAndGetObject, Ok) { bool got_object; std::string object_id; ASSERT_TRUE(internal::EvaluateScriptAndGetObject( - &client, 0, "", &got_object, &object_id).IsOk()); + &client, 0, std::string(), &got_object, &object_id).IsOk()); ASSERT_TRUE(got_object); ASSERT_STREQ("id", object_id.c_str()); } diff --git a/chrome/test/chromedriver/chromedriver.cc b/chrome/test/chromedriver/chromedriver.cc index 40e48fc..8f7ddce0 100644 --- a/chrome/test/chromedriver/chromedriver.cc +++ b/chrome/test/chromedriver/chromedriver.cc @@ -36,7 +36,7 @@ void SetError(const std::string& error_msg, std::string* response) { base::DictionaryValue value; value.SetString("message", error_msg); - SetResponse(kUnknownError, &value, "", response); + SetResponse(kUnknownError, &value, std::string(), response); } } // namespace @@ -120,6 +120,6 @@ void Shutdown() { scoped_ptr<base::Value> value; std::string session_id; g_command_executor->ExecuteCommand( - "quitAll", params, "", &status_code, &value, &session_id); + "quitAll", params, std::string(), &status_code, &value, &session_id); delete g_command_executor; } diff --git a/chrome/test/chromedriver/chromedriver_unittest.cc b/chrome/test/chromedriver/chromedriver_unittest.cc index 91e1e06..9e585e3 100644 --- a/chrome/test/chromedriver/chromedriver_unittest.cc +++ b/chrome/test/chromedriver/chromedriver_unittest.cc @@ -164,7 +164,7 @@ TEST(ChromeDriver, ExecuteCommand) { base::DictionaryValue params; scoped_ptr<base::Value> value(base::Value::CreateNullValue()); mock->Expect(scoped_ptr<ExpectedCommand>(new ExpectedCommand( - "quitAll", params, "", kOk, value.Pass(), ""))); + "quitAll", params, std::string(), kOk, value.Pass(), std::string()))); } Shutdown(); } diff --git a/chrome/test/chromedriver/command_executor_impl_unittest.cc b/chrome/test/chromedriver/command_executor_impl_unittest.cc index f538d06..dafa6e4 100644 --- a/chrome/test/chromedriver/command_executor_impl_unittest.cc +++ b/chrome/test/chromedriver/command_executor_impl_unittest.cc @@ -118,8 +118,11 @@ TEST(CommandExecutorImplTest, CommandThatReturnsError) { StatusCode status_code; scoped_ptr<base::Value> value; std::string out_session_id; - executor.ExecuteCommand("simpleCommand", params, "", - &status_code, &value, + executor.ExecuteCommand("simpleCommand", + params, + std::string(), + &status_code, + &value, &out_session_id); ASSERT_EQ(kUnknownError, status_code); ASSERT_TRUE(value); diff --git a/chrome/test/chromedriver/commands_unittest.cc b/chrome/test/chromedriver/commands_unittest.cc index dabe0e2..dcfc06f 100644 --- a/chrome/test/chromedriver/commands_unittest.cc +++ b/chrome/test/chromedriver/commands_unittest.cc @@ -28,7 +28,8 @@ TEST(CommandsTest, GetStatus) { base::DictionaryValue params; scoped_ptr<base::Value> value; std::string session_id; - ASSERT_EQ(kOk, ExecuteGetStatus(params, "", &value, &session_id).code()); + ASSERT_EQ( + kOk, ExecuteGetStatus(params, std::string(), &value, &session_id).code()); base::DictionaryValue* dict; ASSERT_TRUE(value->GetAsDictionary(&dict)); base::Value* unused; @@ -72,7 +73,7 @@ TEST(CommandsTest, QuitAll) { scoped_ptr<base::Value> value; std::string session_id; Status status = - ExecuteQuitAll(cmd, &map, params, "", &value, &session_id); + ExecuteQuitAll(cmd, &map, params, std::string(), &value, &session_id); ASSERT_EQ(kOk, status.code()); ASSERT_FALSE(value.get()); ASSERT_EQ(2, count); @@ -243,7 +244,7 @@ TEST(CommandsTest, SuccessfulFindElement) { FindElementWebView web_view(true, kElementExistsQueryTwice); Session session("id"); session.implicit_wait = 1000; - session.SwitchToSubFrame("frame_id1", ""); + session.SwitchToSubFrame("frame_id1", std::string()); base::DictionaryValue params; params.SetString("using", "id"); params.SetString("value", "a"); @@ -272,7 +273,7 @@ TEST(CommandsTest, SuccessfulFindElements) { FindElementWebView web_view(false, kElementExistsQueryTwice); Session session("id"); session.implicit_wait = 1000; - session.SwitchToSubFrame("frame_id2", ""); + session.SwitchToSubFrame("frame_id2", std::string()); base::DictionaryValue params; params.SetString("using", "name"); params.SetString("value", "b"); @@ -306,7 +307,7 @@ TEST(CommandsTest, SuccessfulFindChildElement) { FindElementWebView web_view(true, kElementExistsQueryTwice); Session session("id"); session.implicit_wait = 1000; - session.SwitchToSubFrame("frame_id3", ""); + session.SwitchToSubFrame("frame_id3", std::string()); base::DictionaryValue params; params.SetString("using", "tag name"); params.SetString("value", "div"); @@ -344,7 +345,7 @@ TEST(CommandsTest, SuccessfulFindChildElements) { FindElementWebView web_view(false, kElementExistsQueryTwice); Session session("id"); session.implicit_wait = 1000; - session.SwitchToSubFrame("frame_id4", ""); + session.SwitchToSubFrame("frame_id4", std::string()); base::DictionaryValue params; params.SetString("using", "class name"); params.SetString("value", "c"); diff --git a/chrome/test/chromedriver/key_converter.cc b/chrome/test/chromedriver/key_converter.cc index 64c6099..49b95f3 100644 --- a/chrome/test/chromedriver/key_converter.cc +++ b/chrome/test/chromedriver/key_converter.cc @@ -158,11 +158,13 @@ bool KeyCodeFromShorthandKey(char16 key_utf16, } // namespace KeyEvent CreateKeyDownEvent(ui::KeyboardCode key_code, int modifiers) { - return KeyEvent(kRawKeyDownEventType, modifiers, "", "", key_code); + return KeyEvent( + kRawKeyDownEventType, modifiers, std::string(), std::string(), key_code); } KeyEvent CreateKeyUpEvent(ui::KeyboardCode key_code, int modifiers) { - return KeyEvent(kKeyUpEventType, modifiers, "", "", key_code); + return KeyEvent( + kKeyUpEventType, modifiers, std::string(), std::string(), key_code); } KeyEvent CreateCharEvent(const std::string& unmodified_text, diff --git a/chrome/test/chromedriver/keycode_text_conversion_x.cc b/chrome/test/chromedriver/keycode_text_conversion_x.cc index 5b89935..7cf3b32 100644 --- a/chrome/test/chromedriver/keycode_text_conversion_x.cc +++ b/chrome/test/chromedriver/keycode_text_conversion_x.cc @@ -180,7 +180,7 @@ bool GetXModifierMask(Display* display, int modifier, int* x_modifier) { std::string ConvertKeyCodeToText(ui::KeyboardCode key_code, int modifiers) { int x_key_code = KeyboardCodeToXKeyCode(key_code); if (x_key_code == -1) - return ""; + return std::string(); XEvent event; memset(&event, 0, sizeof(XEvent)); @@ -211,7 +211,7 @@ std::string ConvertKeyCodeToText(ui::KeyboardCode key_code, int modifiers) { uint16 character = ui::GetCharacterFromXEvent(&event); if (!character) - return ""; + return std::string(); return UTF16ToUTF8(string16(1, character)); } diff --git a/chrome/test/chromedriver/server/http_handler_unittest.cc b/chrome/test/chromedriver/server/http_handler_unittest.cc index d516902..a4d81a4 100644 --- a/chrome/test/chromedriver/server/http_handler_unittest.cc +++ b/chrome/test/chromedriver/server/http_handler_unittest.cc @@ -56,7 +56,7 @@ TEST(HttpHandlerTest, HandleUnknownCommand) { scoped_ptr<CommandExecutor>(new DummyExecutor()), scoped_ptr<HttpHandler::CommandMap>(new HttpHandler::CommandMap()), "/"); - HttpRequest request(kGet, "/path", ""); + HttpRequest request(kGet, "/path", std::string()); HttpResponse response; handler.Handle(request, &response); ASSERT_EQ(HttpResponse::kNotFound, response.status()); @@ -68,7 +68,7 @@ TEST(HttpHandlerTest, HandleNewSession) { HttpHandler handler( scoped_ptr<CommandExecutor>(new DummyExecutor()), map.Pass(), "/base/"); - HttpRequest request(kPost, "/base/session", ""); + HttpRequest request(kPost, "/base/session", std::string()); HttpResponse response; handler.Handle(request, &response); ASSERT_EQ(HttpResponse::kSeeOther, response.status()); @@ -96,7 +96,7 @@ TEST(HttpHandlerTest, HandleUnimplementedCommand) { HttpHandler handler( scoped_ptr<CommandExecutor>(new DummyExecutor(kUnknownCommand)), map.Pass(), "/"); - HttpRequest request(kPost, "/path", ""); + HttpRequest request(kPost, "/path", std::string()); HttpResponse response; handler.Handle(request, &response); ASSERT_EQ(HttpResponse::kNotImplemented, response.status()); @@ -108,7 +108,7 @@ TEST(HttpHandlerTest, HandleCommand) { HttpHandler handler( scoped_ptr<CommandExecutor>(new DummyExecutor()), map.Pass(), "/"); - HttpRequest request(kPost, "/path", ""); + HttpRequest request(kPost, "/path", std::string()); HttpResponse response; handler.Handle(request, &response); ASSERT_EQ(HttpResponse::kOk, response.status()); @@ -140,9 +140,9 @@ TEST(MatchesCommandTest, DiffPathLength) { ASSERT_FALSE(internal::MatchesCommand( kPost, "path", command, &session_id, ¶ms)); ASSERT_FALSE(internal::MatchesCommand( - kPost, "", command, &session_id, ¶ms)); - ASSERT_FALSE(internal::MatchesCommand( - kPost, "/", command, &session_id, ¶ms)); + kPost, std::string(), command, &session_id, ¶ms)); + ASSERT_FALSE( + internal::MatchesCommand(kPost, "/", command, &session_id, ¶ms)); ASSERT_FALSE(internal::MatchesCommand( kPost, "path/path/path", command, &session_id, ¶ms)); } diff --git a/chrome/test/chromedriver/session.cc b/chrome/test/chromedriver/session.cc index d6f6673..ae10238 100644 --- a/chrome/test/chromedriver/session.cc +++ b/chrome/test/chromedriver/session.cc @@ -67,7 +67,7 @@ void Session::SwitchToSubFrame(const std::string& frame_id, std::string Session::GetCurrentFrameId() const { if (frames.empty()) - return ""; + return std::string(); return frames.back().frame_id; } diff --git a/chrome/test/chromedriver/session_commands.cc b/chrome/test/chromedriver/session_commands.cc index 8fdea23..4be22c4 100644 --- a/chrome/test/chromedriver/session_commands.cc +++ b/chrome/test/chromedriver/session_commands.cc @@ -201,7 +201,8 @@ Status ExecuteSwitchToWindow( status = web_view->ConnectIfNecessary(); if (status.IsError()) return status; - status = web_view->CallFunction("", kGetWindowNameScript, args, &result); + status = web_view->CallFunction( + std::string(), kGetWindowNameScript, args, &result); if (status.IsError()) return status; std::string window_name; diff --git a/chrome/test/chromedriver/window_commands.cc b/chrome/test/chromedriver/window_commands.cc index 557d572..e7b7cd1 100644 --- a/chrome/test/chromedriver/window_commands.cc +++ b/chrome/test/chromedriver/window_commands.cc @@ -347,7 +347,8 @@ Status ExecuteGoBack( WebView* web_view, const base::DictionaryValue& params, scoped_ptr<base::Value>* value) { - return web_view->EvaluateScript("", "window.history.back();", value); + return web_view->EvaluateScript( + std::string(), "window.history.back();", value); } Status ExecuteGoForward( @@ -355,7 +356,8 @@ Status ExecuteGoForward( WebView* web_view, const base::DictionaryValue& params, scoped_ptr<base::Value>* value) { - return web_view->EvaluateScript("", "window.history.forward();", value); + return web_view->EvaluateScript( + std::string(), "window.history.forward();", value); } Status ExecuteRefresh( |