summaryrefslogtreecommitdiffstats
path: root/webkit/appcache/appcache_storage_impl_unittest.cc
diff options
context:
space:
mode:
authormichaeln@google.com <michaeln@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-02-26 00:28:43 +0000
committermichaeln@google.com <michaeln@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-02-26 00:28:43 +0000
commit19eb8015c483fff874bf1eddb80bd26cf4167f33 (patch)
treebe896411dde17d24eb8dbcd67e7b4c5cad2ef1b6 /webkit/appcache/appcache_storage_impl_unittest.cc
parentf02074331bddc7d89b20e6b3a8fb934e6891207c (diff)
downloadchromium_src-19eb8015c483fff874bf1eddb80bd26cf4167f33.zip
chromium_src-19eb8015c483fff874bf1eddb80bd26cf4167f33.tar.gz
chromium_src-19eb8015c483fff874bf1eddb80bd26cf4167f33.tar.bz2
Add an accessor for an ExtensionSpecialStoragePolicy to the Profile class
and use it in the extension service, data remover, and storage subsystems. BUG=52357 TEST=extension_service_unittest.cc Review URL: http://codereview.chromium.org/6551028 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@76126 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/appcache/appcache_storage_impl_unittest.cc')
-rw-r--r--webkit/appcache/appcache_storage_impl_unittest.cc15
1 files changed, 3 insertions, 12 deletions
diff --git a/webkit/appcache/appcache_storage_impl_unittest.cc b/webkit/appcache/appcache_storage_impl_unittest.cc
index 2f25b65..1d874bc 100644
--- a/webkit/appcache/appcache_storage_impl_unittest.cc
+++ b/webkit/appcache/appcache_storage_impl_unittest.cc
@@ -547,19 +547,14 @@ class AppCacheStorageImplTest : public testing::Test {
PushNextTask(NewRunnableMethod(
this, &AppCacheStorageImplTest::Verify_FailStoreGroup));
- // Set a low quota to force a failure.
- const GURL kOrigin(kManifestUrl.GetOrigin());
- EXPECT_EQ(-1L, storage()->GetOriginQuotaInMemory(kOrigin));
- storage()->SetOriginQuotaInMemory(kManifestUrl.GetOrigin(), 0);
- EXPECT_EQ(0L, storage()->GetOriginQuotaInMemory(kOrigin));
-
// Setup some preconditions. Create a group and newest cache that
- // appear to be "unstored".
+ // appear to be "unstored" and big enough to exceed the 5M limit.
+ const int64 kTooBig = 10 * 1024 * 1024; // 10M
group_ = new AppCacheGroup(
service(), kManifestUrl, storage()->NewGroupId());
cache_ = new AppCache(service(), storage()->NewCacheId());
cache_->AddEntry(kManifestUrl,
- AppCacheEntry(AppCacheEntry::MANIFEST, 1, 1024));
+ AppCacheEntry(AppCacheEntry::MANIFEST, 1, kTooBig));
// Hold a ref to the cache simulate the UpdateJob holding that ref,
// and hold a ref to the group to simulate the CacheHost holding that ref.
@@ -578,10 +573,6 @@ class AppCacheStorageImplTest : public testing::Test {
EXPECT_FALSE(database()->FindGroup(group_->group_id(), &group_record));
EXPECT_FALSE(database()->FindCache(cache_->cache_id(), &cache_record));
- const GURL kOrigin(kManifestUrl.GetOrigin());
- storage()->ResetOriginQuotaInMemory(kOrigin);
- EXPECT_EQ(-1L, storage()->GetOriginQuotaInMemory(kOrigin));
-
TestFinished();
}