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

Unified Diff: components/data_reduction_proxy/core/browser/data_reduction_proxy_config_test_utils.h

Issue 1024553009: Add the ability to use DataReductionProxyParams from DataReductionProxyConfigServiceClient. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@client_control_local
Patch Set: Forgot implementation of DataReductionProxyMutableConfigValues::IsDataReductionProxy in downstream … Created 5 years, 9 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_config_test_utils.h
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_config_test_utils.h b/components/data_reduction_proxy/core/browser/data_reduction_proxy_config_test_utils.h
index 79c5548010bdd78dafef22d79e70d34df71a3482..28ae85995946e8b74c3f8ef36a02c7e24a52b0e9 100644
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_config_test_utils.h
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_config_test_utils.h
@@ -23,6 +23,7 @@ namespace data_reduction_proxy {
class DataReductionProxyConfigurator;
class DataReductionProxyEventStore;
+class DataReductionProxyMutableConfigValues;
class TestDataReductionProxyParams;
// Test version of |DataReductionProxyConfig|, which uses an underlying
@@ -39,6 +40,14 @@ class TestDataReductionProxyConfig : public DataReductionProxyConfig {
net::NetLog* net_log,
DataReductionProxyConfigurator* configurator,
DataReductionProxyEventStore* event_store);
+
+ TestDataReductionProxyConfig(
bengr 2015/03/24 21:37:41 Add comment that explains how this Constructor is
jeremyim 2015/03/24 23:20:28 Done.
+ scoped_ptr<DataReductionProxyConfigValues> config_values,
sclittle 2015/03/24 21:34:55 Could this be changed to scoped_ptr<DataReductionP
jeremyim 2015/03/24 23:20:28 I actually pass TestDataReductionProxyParams in fr
+ scoped_refptr<base::SingleThreadTaskRunner> task_runner,
+ net::NetLog* net_log,
+ DataReductionProxyConfigurator* configurator,
+ DataReductionProxyEventStore* event_store);
+
~TestDataReductionProxyConfig() override;
void GetNetworkList(net::NetworkInterfaceList* interfaces,
@@ -53,11 +62,13 @@ class TestDataReductionProxyConfig : public DataReductionProxyConfig {
// Retrieves the test params being used for the configuration.
TestDataReductionProxyParams* test_params();
+ // Retrieves the mutable config values.
+ DataReductionProxyMutableConfigValues* mutable_config_values();
+
// Allows tests to set the internal state.
void SetStateForTest(bool enabled_by_user,
bool alternative_enabled_by_user,
- bool restricted_by_carrier,
- bool at_startup);
+ bool restricted_by_carrier);
net::NetworkInterfaceList* interfaces() {
return network_interfaces_.get();
@@ -71,10 +82,9 @@ class TestDataReductionProxyConfig : public DataReductionProxyConfig {
// testing.
class MockDataReductionProxyConfig : public TestDataReductionProxyConfig {
public:
- // Creates a |MockDataReductionProxyConfig| with the provided |params_flags|.
+ // Creates a |MockDataReductionProxyConfig|.
MockDataReductionProxyConfig(
- int params_flags,
- unsigned int params_definitions,
+ scoped_ptr<DataReductionProxyConfigValues> config_values,
scoped_refptr<base::SingleThreadTaskRunner> network_task_runner,
net::NetLog* net_log,
DataReductionProxyConfigurator* configurator,

Powered by Google App Engine
This is Rietveld 408576698