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

Unified Diff: content/renderer/dom_serializer_browsertest.cc

Issue 2656043002: Use explicit WebString conversions in remaining content files (Closed)
Patch Set: build fix Created 3 years, 11 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/renderer/dom_serializer_browsertest.cc
diff --git a/content/renderer/dom_serializer_browsertest.cc b/content/renderer/dom_serializer_browsertest.cc
index edd3542d34ef5f5db4878f655c47e3baba381482..bcda8439cb4134db88af359755fb09ad75f7936e 100644
--- a/content/renderer/dom_serializer_browsertest.cc
+++ b/content/renderer/dom_serializer_browsertest.cc
@@ -192,8 +192,7 @@ class DomSerializerTests : public ContentBrowserTest,
// Find corresponding WebFrame according to frame_url.
WebFrame* web_frame = FindSubFrameByURL(frame_url);
ASSERT_TRUE(web_frame != NULL);
- WebString file_path =
- base::FilePath(FILE_PATH_LITERAL("c:\\dummy.htm")).AsUTF16Unsafe();
+ WebString file_path = WebString::fromUTF8("c:\\dummy.htm");
SingleLinkRewritingDelegate delegate(frame_url, file_path);
// Start serializing DOM.
bool result = WebFrameSerializer::serialize(web_frame->toWebLocalFrame(),
@@ -474,8 +473,8 @@ class DomSerializerTests : public ContentBrowserTest,
};
WebString value = body_element.getAttribute("title");
WebString content = doc.contentAsTextForTesting();
- ASSERT_TRUE(base::UTF16ToWide(value) == parsed_value);
- ASSERT_TRUE(base::UTF16ToWide(content) == parsed_value);
+ ASSERT_TRUE(base::UTF16ToWide(value.utf16()) == parsed_value);
+ ASSERT_TRUE(base::UTF16ToWide(content.utf16()) == parsed_value);
// Do serialization.
SerializeDomForURL(file_url);

Powered by Google App Engine
This is Rietveld 408576698