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

Unified Diff: base/pickle_unittest.cc

Issue 38693003: Remove Pickle::BeginWriteData/TrimWriteData, it's not used (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 2 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 | « base/pickle.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/pickle_unittest.cc
diff --git a/base/pickle_unittest.cc b/base/pickle_unittest.cc
index cc384c70617ae354ae31b8bc7a52c7c4cf9fce6e..dd00e6a5d4db4657ecf4f2f3bc363aea4dc6db82 100644
--- a/base/pickle_unittest.cc
+++ b/base/pickle_unittest.cc
@@ -58,10 +58,6 @@ void VerifyResult(const Pickle& pickle) {
EXPECT_EQ(testdatalen, outdatalen);
EXPECT_EQ(memcmp(testdata, outdata, outdatalen), 0);
- EXPECT_TRUE(pickle.ReadData(&iter, &outdata, &outdatalen));
- EXPECT_EQ(testdatalen, outdatalen);
- EXPECT_EQ(memcmp(testdata, outdata, outdatalen), 0);
-
// reads past the end should fail
EXPECT_FALSE(pickle.ReadInt(&iter, &outint));
}
@@ -79,14 +75,6 @@ TEST(PickleTest, EncodeDecode) {
EXPECT_TRUE(pickle.WriteUInt16(testuint16));
EXPECT_TRUE(pickle.WriteFloat(testfloat));
EXPECT_TRUE(pickle.WriteData(testdata, testdatalen));
-
- // Over allocate BeginWriteData so we can test TrimWriteData.
- char* dest = pickle.BeginWriteData(testdatalen + 100);
- EXPECT_TRUE(dest);
- memcpy(dest, testdata, testdatalen);
-
- pickle.TrimWriteData(testdatalen);
-
VerifyResult(pickle);
// test copy constructor
« no previous file with comments | « base/pickle.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698