summaryrefslogtreecommitdiffstats
path: root/webkit/appcache/appcache_storage_impl_unittest.cc
diff options
context:
space:
mode:
authormichaeln@chromium.org <michaeln@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-06 03:26:41 +0000
committermichaeln@chromium.org <michaeln@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-06 03:26:41 +0000
commitfd4882e6faab19e1de6d791acebfa3b34faf5701 (patch)
tree2fa95bddd8b6189d0dd7b850d24da0b7ab382e28 /webkit/appcache/appcache_storage_impl_unittest.cc
parent12e8fecd3923d3ace7fe3f505ba3fa490b5417c1 (diff)
downloadchromium_src-fd4882e6faab19e1de6d791acebfa3b34faf5701.zip
chromium_src-fd4882e6faab19e1de6d791acebfa3b34faf5701.tar.gz
chromium_src-fd4882e6faab19e1de6d791acebfa3b34faf5701.tar.bz2
AppCache quota tracking groundwork, store response sizes in the SQL database.
TEST=updated existing unittests BUG=none Review URL: http://codereview.chromium.org/523046 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@35609 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/appcache/appcache_storage_impl_unittest.cc')
-rw-r--r--webkit/appcache/appcache_storage_impl_unittest.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/webkit/appcache/appcache_storage_impl_unittest.cc b/webkit/appcache/appcache_storage_impl_unittest.cc
index 1db4aa8..cbb366a 100644
--- a/webkit/appcache/appcache_storage_impl_unittest.cc
+++ b/webkit/appcache/appcache_storage_impl_unittest.cc
@@ -458,7 +458,7 @@ class AppCacheStorageImplTest : public testing::Test {
// Change the cache.
base::TimeTicks now = base::TimeTicks::Now();
- cache_->AddEntry(kEntryUrl, AppCacheEntry(AppCacheEntry::MASTER));
+ cache_->AddEntry(kEntryUrl, AppCacheEntry(AppCacheEntry::MASTER, 1, 100));
cache_->set_update_time(now);
PushNextTask(method_factory_.NewRunnableMethod(
@@ -482,6 +482,7 @@ class AppCacheStorageImplTest : public testing::Test {
EXPECT_EQ(1, cache_record.group_id);
EXPECT_FALSE(cache_record.online_wildcard);
EXPECT_TRUE(expected_update_time == cache_record.update_time);
+ EXPECT_EQ(100, cache_record.cache_size);
std::vector<AppCacheDatabase::EntryRecord> entry_records;
EXPECT_TRUE(database()->FindEntriesForCache(1, &entry_records));
@@ -489,7 +490,8 @@ class AppCacheStorageImplTest : public testing::Test {
EXPECT_EQ(1 , entry_records[0].cache_id);
EXPECT_EQ(kEntryUrl, entry_records[0].url);
EXPECT_EQ(AppCacheEntry::MASTER, entry_records[0].flags);
- EXPECT_EQ(0, entry_records[0].response_id);
+ EXPECT_EQ(1, entry_records[0].response_id);
+ EXPECT_EQ(100, entry_records[0].response_size);
TestFinished();
}