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

Unified Diff: components/data_reduction_proxy/core/browser/data_reduction_proxy_compression_stats_unittest.cc

Issue 1173343009: LevelDB storage for data reduction proxy to store data usage stats. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use raw pointers for arguments instead of ref counting Created 5 years, 6 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: components/data_reduction_proxy/core/browser/data_reduction_proxy_compression_stats_unittest.cc
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_compression_stats_unittest.cc b/components/data_reduction_proxy/core/browser/data_reduction_proxy_compression_stats_unittest.cc
index aad3de816fc8f087561e9f2943148d63ba93aa04..4ca244ab2dd4c6e86e59f382f323efb855be2104 100644
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_compression_stats_unittest.cc
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_compression_stats_unittest.cc
@@ -14,6 +14,7 @@
#include "base/values.h"
#include "components/data_reduction_proxy/core/browser/data_reduction_proxy_compression_stats.h"
#include "components/data_reduction_proxy/core/browser/data_reduction_proxy_prefs.h"
+#include "components/data_reduction_proxy/core/browser/data_reduction_proxy_store.h"
#include "components/data_reduction_proxy/core/common/data_reduction_proxy_pref_names.h"
#include "components/data_reduction_proxy/core/common/data_reduction_proxy_switches.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -51,14 +52,18 @@ class DataReductionProxyCompressionStatsTest : public testing::Test {
}
void SetUp() override {
+ scoped_refptr<DataReductionProxyStore> store(
+ new DummyDataReductionProxyStore());
compression_stats_.reset(new DataReductionProxyCompressionStats(
- pref_service(), task_runner_, base::TimeDelta()));
+ pref_service(), task_runner_, task_runner_, store, base::TimeDelta()));
RegisterSimpleProfilePrefs(pref_service()->registry());
}
void ResetCompressionStatsWithDelay(const base::TimeDelta& delay) {
+ scoped_refptr<DataReductionProxyStore> store(
+ new DummyDataReductionProxyStore());
compression_stats_.reset(new DataReductionProxyCompressionStats(
- pref_service(), task_runner_, delay));
+ pref_service(), task_runner_, task_runner_, store, delay));
}
base::Time FakeNow() const {

Powered by Google App Engine
This is Rietveld 408576698