summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-01-22 01:44:23 +0000
committertfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-01-22 01:44:23 +0000
commit22148ab57bb3c8743ea86f593f883f56bf0dd876 (patch)
treee2da208890c298e883b44150ada0b868bd05f83c
parentd4a42b3c31aadfa6d87ed11e246c090d2f2d1c45 (diff)
downloadchromium_src-22148ab57bb3c8743ea86f593f883f56bf0dd876.zip
chromium_src-22148ab57bb3c8743ea86f593f883f56bf0dd876.tar.gz
chromium_src-22148ab57bb3c8743ea86f593f883f56bf0dd876.tar.bz2
Convert to std::wstring as late as possible.
This is the change requested by Will. BUG=None TEST=None Original Review URL: http://codereview.chromium.org/6243010/ Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: William Chan <willchan@chromium.org> Reviewed-by: Thiago Farina <tfarina@chromium.org> Review URL: http://codereview.chromium.org/6299015 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@72254 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/test/url_fetch_test/url_fetch_test.cc21
1 files changed, 11 insertions, 10 deletions
diff --git a/chrome/test/url_fetch_test/url_fetch_test.cc b/chrome/test/url_fetch_test/url_fetch_test.cc
index 49156f8..5f1607c 100644
--- a/chrome/test/url_fetch_test/url_fetch_test.cc
+++ b/chrome/test/url_fetch_test/url_fetch_test.cc
@@ -53,8 +53,8 @@ class UrlFetchTest : public UITest {
const char* wait_cookie_name,
const char* wait_cookie_value,
const char* var_to_fetch,
- const std::wstring& wait_js_expr,
- const std::wstring& wait_js_frame_xpath,
+ const std::string& wait_js_expr,
+ const std::string& wait_js_frame_xpath,
int wait_js_timeout_ms,
UrlFetchTestResult* result) {
scoped_refptr<TabProxy> tab(GetActiveTab());
@@ -74,10 +74,11 @@ class UrlFetchTest : public UITest {
ASSERT_TRUE(result->cookie_value.length());
}
} else if (!wait_js_expr.empty()) {
- bool completed = WaitUntilJavaScriptCondition(tab.get(),
- wait_js_frame_xpath,
- wait_js_expr,
- wait_js_timeout_ms);
+ bool completed = WaitUntilJavaScriptCondition(
+ tab.get(),
+ UTF8ToWide(wait_js_frame_xpath),
+ UTF8ToWide(wait_js_expr),
+ wait_js_timeout_ms);
ASSERT_TRUE(completed);
}
if (var_to_fetch) {
@@ -150,10 +151,10 @@ TEST_F(UrlFetchTest, UrlFetch) {
cmd_line->GetSwitchValueASCII("wait_cookie_name");
std::string cookie_value =
cmd_line->GetSwitchValueASCII("wait_cookie_value");
- std::wstring js_expr =
- UTF8ToWide(cmd_line->GetSwitchValueASCII("wait_js_expr"));
- std::wstring js_frame_xpath =
- UTF8ToWide(cmd_line->GetSwitchValueASCII("wait_js_frame_xpath"));
+ std::string js_expr =
+ cmd_line->GetSwitchValueASCII("wait_js_expr");
+ std::string js_frame_xpath =
+ cmd_line->GetSwitchValueASCII("wait_js_frame_xpath");
std::string js_timeout_ms_str =
cmd_line->GetSwitchValueASCII("wait_js_timeout");