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

Side by Side Diff: chrome/browser/browsing_data/browsing_data_quota_helper_unittest.cc

Issue 136573007: Quota: Factor out (Mock)QuotaManagerProxy into its own file for readability (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review fix Created 6 years, 11 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/chrome_tests_unit.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "testing/gtest/include/gtest/gtest.h" 5 #include "testing/gtest/include/gtest/gtest.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/files/scoped_temp_dir.h" 8 #include "base/files/scoped_temp_dir.h"
9 #include "base/memory/weak_ptr.h" 9 #include "base/memory/weak_ptr.h"
10 #include "base/message_loop/message_loop.h" 10 #include "base/message_loop/message_loop.h"
11 #include "base/message_loop/message_loop_proxy.h" 11 #include "base/message_loop/message_loop_proxy.h"
12 #include "chrome/browser/browsing_data/browsing_data_quota_helper_impl.h" 12 #include "chrome/browser/browsing_data/browsing_data_quota_helper_impl.h"
13 #include "content/public/test/test_browser_thread.h" 13 #include "content/public/test/test_browser_thread.h"
14 #include "content/public/test/test_browser_thread_bundle.h" 14 #include "content/public/test/test_browser_thread_bundle.h"
15 #include "webkit/browser/quota/mock_storage_client.h" 15 #include "webkit/browser/quota/mock_storage_client.h"
16 #include "webkit/browser/quota/quota_manager.h" 16 #include "webkit/browser/quota/quota_manager.h"
17 #include "webkit/browser/quota/quota_manager_proxy.h"
17 18
18 using content::BrowserThread; 19 using content::BrowserThread;
19 20
20 class BrowsingDataQuotaHelperTest : public testing::Test { 21 class BrowsingDataQuotaHelperTest : public testing::Test {
21 public: 22 public:
22 typedef BrowsingDataQuotaHelper::QuotaInfo QuotaInfo; 23 typedef BrowsingDataQuotaHelper::QuotaInfo QuotaInfo;
23 typedef BrowsingDataQuotaHelper::QuotaInfoArray QuotaInfoArray; 24 typedef BrowsingDataQuotaHelper::QuotaInfoArray QuotaInfoArray;
24 25
25 BrowsingDataQuotaHelperTest() 26 BrowsingDataQuotaHelperTest()
26 : fetching_completed_(true), 27 : fetching_completed_(true),
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 base::MessageLoop::current()->RunUntilIdle(); 195 base::MessageLoop::current()->RunUntilIdle();
195 196
196 GetPersistentHostQuota(kHost1); 197 GetPersistentHostQuota(kHost1);
197 base::MessageLoop::current()->RunUntilIdle(); 198 base::MessageLoop::current()->RunUntilIdle();
198 EXPECT_EQ(0, quota()); 199 EXPECT_EQ(0, quota());
199 200
200 GetPersistentHostQuota(kHost2); 201 GetPersistentHostQuota(kHost2);
201 base::MessageLoop::current()->RunUntilIdle(); 202 base::MessageLoop::current()->RunUntilIdle();
202 EXPECT_EQ(10, quota()); 203 EXPECT_EQ(10, quota());
203 } 204 }
OLDNEW
« no previous file with comments | « no previous file | chrome/chrome_tests_unit.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698