summaryrefslogtreecommitdiffstats
path: root/chrome/test
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/test')
-rw-r--r--chrome/test/ui/ui_test.cc8
-rw-r--r--chrome/test/ui/ui_test_suite.h3
2 files changed, 5 insertions, 6 deletions
diff --git a/chrome/test/ui/ui_test.cc b/chrome/test/ui/ui_test.cc
index d7bb7ca..2124ba7 100644
--- a/chrome/test/ui/ui_test.cc
+++ b/chrome/test/ui/ui_test.cc
@@ -186,27 +186,27 @@ void UITest::InitializeTimeouts() {
const CommandLine& command_line = *CommandLine::ForCurrentProcess();
if (command_line.HasSwitch(kUiTestTimeout)) {
std::wstring timeout_str = command_line.GetSwitchValue(kUiTestTimeout);
- int timeout = StringToInt(timeout_str);
+ int timeout = StringToInt(WideToUTF16Hack(timeout_str));
command_execution_timeout_ms_ = std::max(kMaxTestExecutionTime, timeout);
}
if (command_line.HasSwitch(kUiTestActionTimeout)) {
std::wstring act_str = command_line.GetSwitchValue(kUiTestActionTimeout);
- int act_timeout = StringToInt(act_str);
+ int act_timeout = StringToInt(WideToUTF16Hack(act_str));
action_timeout_ms_ = std::max(kWaitForActionMsec, act_timeout);
}
if (command_line.HasSwitch(kUiTestActionMaxTimeout)) {
std::wstring action_max_str =
command_line.GetSwitchValue(kUiTestActionMaxTimeout);
- int max_timeout = StringToInt(action_max_str);
+ int max_timeout = StringToInt(WideToUTF16Hack(action_max_str));
action_max_timeout_ms_ = std::max(kWaitForActionMaxMsec, max_timeout);
}
if (CommandLine::ForCurrentProcess()->HasSwitch(kUiTestSleepTimeout)) {
std::wstring sleep_timeout_str =
CommandLine::ForCurrentProcess()->GetSwitchValue(kUiTestSleepTimeout);
- int sleep_timeout = StringToInt(sleep_timeout_str);
+ int sleep_timeout = StringToInt(WideToUTF16Hack(sleep_timeout_str));
sleep_timeout_ms_ = std::max(kWaitForActionMsec, sleep_timeout);
}
}
diff --git a/chrome/test/ui/ui_test_suite.h b/chrome/test/ui/ui_test_suite.h
index dfe5eeb..d450a71 100644
--- a/chrome/test/ui/ui_test_suite.h
+++ b/chrome/test/ui/ui_test_suite.h
@@ -42,7 +42,7 @@ class UITestSuite : public ChromeTestSuite {
std::wstring test_timeout =
parsed_command_line.GetSwitchValue(UITestSuite::kTestTimeout);
if (!test_timeout.empty()) {
- UITest::set_test_timeout_ms(StringToInt(test_timeout));
+ UITest::set_test_timeout_ms(StringToInt(WideToUTF16Hack(test_timeout)));
}
std::wstring js_flags =
parsed_command_line.GetSwitchValue(switches::kJavaScriptFlags);
@@ -69,4 +69,3 @@ class UITestSuite : public ChromeTestSuite {
};
#endif // CHROME_TEST_UI_UI_TEST_SUITE_H_
-