OLD | NEW |
| (Empty) |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CHROME_BROWSER_MOCK_BROWSING_DATA_QUOTA_HELPER_H_ | |
6 #define CHROME_BROWSER_MOCK_BROWSING_DATA_QUOTA_HELPER_H_ | |
7 | |
8 #include <list> | |
9 #include <string> | |
10 | |
11 #include "base/compiler_specific.h" | |
12 #include "chrome/browser/browsing_data_quota_helper.h" | |
13 | |
14 class MockBrowsingDataQuotaHelper : public BrowsingDataQuotaHelper { | |
15 public: | |
16 explicit MockBrowsingDataQuotaHelper(Profile* profile); | |
17 | |
18 virtual void StartFetching(const FetchResultCallback& callback) OVERRIDE; | |
19 virtual void RevokeHostQuota(const std::string& host) OVERRIDE; | |
20 | |
21 void AddHost(const std::string& host, | |
22 int64 temporary_usage, | |
23 int64 persistent_usage); | |
24 void AddQuotaSamples(); | |
25 void Notify(); | |
26 | |
27 private: | |
28 virtual ~MockBrowsingDataQuotaHelper(); | |
29 | |
30 FetchResultCallback callback_; | |
31 std::list<QuotaInfo> response_; | |
32 }; | |
33 | |
34 #endif // CHROME_BROWSER_MOCK_BROWSING_DATA_QUOTA_HELPER_H_ | |
OLD | NEW |