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

Unified Diff: ui/base/clipboard/custom_data_helper_unittest.cc

Issue 1154283003: Change most uses of Pickle to base::Pickle (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 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
« no previous file with comments | « ui/base/clipboard/custom_data_helper.cc ('k') | ui/base/clipboard/scoped_clipboard_writer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/clipboard/custom_data_helper_unittest.cc
diff --git a/ui/base/clipboard/custom_data_helper_unittest.cc b/ui/base/clipboard/custom_data_helper_unittest.cc
index a765852aad37a8c7466f091d743d57a23f3eabd9..1ed53c667505b88debbf2c5b484d67f898692a54 100644
--- a/ui/base/clipboard/custom_data_helper_unittest.cc
+++ b/ui/base/clipboard/custom_data_helper_unittest.cc
@@ -16,12 +16,12 @@ namespace ui {
namespace {
-void PrepareEmptyTestData(Pickle* pickle) {
+void PrepareEmptyTestData(base::Pickle* pickle) {
std::map<base::string16, base::string16> data;
WriteCustomDataToPickle(data, pickle);
}
-void PrepareTestData(Pickle* pickle) {
+void PrepareTestData(base::Pickle* pickle) {
std::map<base::string16, base::string16> data;
data.insert(std::make_pair(ASCIIToUTF16("abc"), base::string16()));
data.insert(std::make_pair(ASCIIToUTF16("de"), ASCIIToUTF16("1")));
@@ -30,7 +30,7 @@ void PrepareTestData(Pickle* pickle) {
}
TEST(CustomDataHelperTest, EmptyReadTypes) {
- Pickle pickle;
+ base::Pickle pickle;
PrepareEmptyTestData(&pickle);
std::vector<base::string16> types;
@@ -39,7 +39,7 @@ TEST(CustomDataHelperTest, EmptyReadTypes) {
}
TEST(CustomDataHelperTest, EmptyReadSingleType) {
- Pickle pickle;
+ base::Pickle pickle;
PrepareEmptyTestData(&pickle);
base::string16 result;
@@ -51,7 +51,7 @@ TEST(CustomDataHelperTest, EmptyReadSingleType) {
}
TEST(CustomDataHelperTest, EmptyReadMap) {
- Pickle pickle;
+ base::Pickle pickle;
PrepareEmptyTestData(&pickle);
std::map<base::string16, base::string16> result;
@@ -60,7 +60,7 @@ TEST(CustomDataHelperTest, EmptyReadMap) {
}
TEST(CustomDataHelperTest, ReadTypes) {
- Pickle pickle;
+ base::Pickle pickle;
PrepareTestData(&pickle);
std::vector<base::string16> types;
@@ -74,7 +74,7 @@ TEST(CustomDataHelperTest, ReadTypes) {
}
TEST(CustomDataHelperTest, ReadSingleType) {
- Pickle pickle;
+ base::Pickle pickle;
PrepareTestData(&pickle);
base::string16 result;
@@ -98,7 +98,7 @@ TEST(CustomDataHelperTest, ReadSingleType) {
}
TEST(CustomDataHelperTest, ReadMap) {
- Pickle pickle;
+ base::Pickle pickle;
PrepareTestData(&pickle);
std::map<base::string16, base::string16> result;
@@ -119,7 +119,7 @@ TEST(CustomDataHelperTest, BadReadTypes) {
expected.push_back(ASCIIToUTF16("de"));
expected.push_back(ASCIIToUTF16("f"));
- Pickle malformed;
+ base::Pickle malformed;
malformed.WriteSizeT(1000);
malformed.WriteString16(ASCIIToUTF16("hello"));
malformed.WriteString16(ASCIIToUTF16("world"));
@@ -127,7 +127,7 @@ TEST(CustomDataHelperTest, BadReadTypes) {
ReadCustomDataTypes(malformed.data(), malformed.size(), &actual);
EXPECT_EQ(expected, actual);
- Pickle malformed2;
+ base::Pickle malformed2;
malformed2.WriteSizeT(1);
malformed2.WriteString16(ASCIIToUTF16("hello"));
std::vector<base::string16> actual2(expected);
@@ -139,7 +139,7 @@ TEST(CustomDataHelperTest, BadPickle) {
base::string16 result_data;
std::map<base::string16, base::string16> result_map;
- Pickle malformed;
+ base::Pickle malformed;
malformed.WriteSizeT(1000);
malformed.WriteString16(ASCIIToUTF16("hello"));
malformed.WriteString16(ASCIIToUTF16("world"));
@@ -152,7 +152,7 @@ TEST(CustomDataHelperTest, BadPickle) {
EXPECT_EQ(0u, result_data.size());
EXPECT_EQ(0u, result_map.size());
- Pickle malformed2;
+ base::Pickle malformed2;
malformed2.WriteSizeT(1);
malformed2.WriteString16(ASCIIToUTF16("hello"));
« no previous file with comments | « ui/base/clipboard/custom_data_helper.cc ('k') | ui/base/clipboard/scoped_clipboard_writer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698