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

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

Issue 1124073008: Base Data Reduction Proxy configuration on vectors of servers per origin scheme. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: bengr CR comments Created 5 years, 7 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_configurator_test_utils.h
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_configurator_test_utils.h b/components/data_reduction_proxy/core/browser/data_reduction_proxy_configurator_test_utils.h
index 9125bfd6ed6d4cdb5b2d8c6009b2bd9135009f31..ac7093cf414aedd113cc56a91e6fc457803de45d 100644
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_configurator_test_utils.h
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_configurator_test_utils.h
@@ -6,11 +6,13 @@
#define COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_DATA_REDUCTION_PROXY_CONFIGURATOR_TEST_UTILS_H_
#include <string>
+#include <vector>
#include "components/data_reduction_proxy/core/browser/data_reduction_proxy_configurator.h"
namespace net {
class NetLog;
+class ProxyServer;
}
namespace data_reduction_proxy {
@@ -26,11 +28,9 @@ class TestDataReductionProxyConfigurator
~TestDataReductionProxyConfigurator() override;
// Overrides of DataReductionProxyConfigurator
- void Enable(bool restricted,
- bool fallback_restricted,
- const std::string& primary_origin,
- const std::string& fallback_origin,
- const std::string& ssl_origin) override;
+ void Enable(bool secure_transport_restricted,
+ const std::vector<net::ProxyServer>& proxies_for_http,
+ const std::vector<net::ProxyServer>& proxies_for_https) override;
void Disable() override;
@@ -46,20 +46,12 @@ class TestDataReductionProxyConfigurator
return restricted_;
}
- bool fallback_restricted() const {
- return fallback_restricted_;
+ const std::vector<net::ProxyServer>& proxies_for_http() const {
+ return proxies_for_http_;
}
- const std::string& origin() const {
- return origin_;
- }
-
- const std::string& fallback_origin() const {
- return fallback_origin_;
- }
-
- const std::string& ssl_origin() const {
- return ssl_origin_;
+ const std::vector<net::ProxyServer>& proxies_for_https() const {
+ return proxies_for_https_;
}
private:
@@ -68,18 +60,13 @@ class TestDataReductionProxyConfigurator
bool enabled_;
// Describes whether the proxy has been put in a restricted mode. True if
- // |Enable| is called with |restricted| set to true. Defaults to false.
+ // |Enable| is called with |secure_transport_restricted| set to true. Defaults
+ // to false.
bool restricted_;
- // Describes whether the proxy has been put in a mode where the fallback
- // configuration has been disallowed. True if |Enable| is called with
- // |fallback_restricted| set to true. Defaults to false.
- bool fallback_restricted_;
-
// The origins that are passed to |Enable|.
- std::string origin_;
- std::string fallback_origin_;
- std::string ssl_origin_;
+ std::vector<net::ProxyServer> proxies_for_http_;
+ std::vector<net::ProxyServer> proxies_for_https_;
};
} // namespace data_reduction_proxy

Powered by Google App Engine
This is Rietveld 408576698