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

Unified Diff: webkit/dom_storage/dom_storage_map_unittest.cc

Issue 9594038: Relax strict quota limit checks when reading pre-existing DomStorage database files. The other chec… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 10 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: webkit/dom_storage/dom_storage_map_unittest.cc
===================================================================
--- webkit/dom_storage/dom_storage_map_unittest.cc (revision 124748)
+++ webkit/dom_storage/dom_storage_map_unittest.cc (working copy)
@@ -37,7 +37,7 @@
copy = map->DeepCopy();
EXPECT_EQ(0u, copy->Length());
EXPECT_EQ(0u, copy->bytes_used());
- EXPECT_TRUE(map->SwapValues(&swap));
+ map->SwapValues(&swap);
EXPECT_TRUE(swap.empty());
// Check the behavior of a map containing some values.
@@ -76,7 +76,7 @@
EXPECT_TRUE(copy->Key(2).is_null());
EXPECT_EQ(kItemBytes + kItem2Bytes, copy->bytes_used());
- EXPECT_TRUE(map->SwapValues(&swap));
+ map->SwapValues(&swap);
EXPECT_EQ(2ul, swap.size());
EXPECT_EQ(0u, map->Length());
EXPECT_EQ(0u, map->bytes_used());
@@ -106,15 +106,8 @@
EXPECT_EQ(1u, map->Length());
ValuesMap swap;
- EXPECT_TRUE(map->SwapValues(&swap));
+ map->SwapValues(&swap);
benm (inactive) 2012/03/06 11:31:15 What is this bit of the test verifying now? I thin
michaeln 2012/03/06 20:37:51 Done, added tests to verify the quota checking beh
EXPECT_EQ(0u, map->Length());
-
- swap[kKey] = NullableString16(kValue, false);
- swap[kKey2] = NullableString16(kValue, false);
-
- // swap is now too big to fit in the map, the swap should fail.
- EXPECT_FALSE(map->SwapValues(&swap));
- EXPECT_EQ(0u, map->Length());
}
} // namespace dom_storage
« webkit/dom_storage/dom_storage_map.cc ('K') | « webkit/dom_storage/dom_storage_map.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698