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

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

Issue 1132083004: Enable an option to only use the secure Data Reduction Proxy when the secure proxy check succeeds. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase 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_settings_unittest.cc
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_settings_unittest.cc b/components/data_reduction_proxy/core/browser/data_reduction_proxy_settings_unittest.cc
index b169f30af99e6252ab62df2e31d2d2244d5583cc..ee474d581b76886ab9671fb8c9be229a86e96ee9 100644
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_settings_unittest.cc
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_settings_unittest.cc
@@ -36,7 +36,7 @@ class DataReductionProxySettingsTest
test_context_->pref_service()->SetBoolean(prefs::kDataReductionProxyEnabled,
initially_enabled);
test_context_->config()->SetStateForTest(initially_enabled, false,
- !request_succeeded);
+ request_succeeded);
ExpectSetProxyPrefs(expected_enabled, false, false);
settings_->MaybeActivateDataReductionProxy(false);
test_context_->RunUntilIdle();
@@ -46,7 +46,7 @@ class DataReductionProxySettingsTest
TEST_F(DataReductionProxySettingsTest, TestIsProxyEnabledOrManaged) {
settings_->InitPrefMembers();
// The proxy is disabled initially.
- test_context_->config()->SetStateForTest(false, false, false);
+ test_context_->config()->SetStateForTest(false, false, true);
EXPECT_FALSE(settings_->IsDataReductionProxyEnabled());
EXPECT_FALSE(settings_->IsDataReductionProxyManaged());
@@ -65,7 +65,7 @@ TEST_F(DataReductionProxySettingsTest, TestIsProxyEnabledOrManaged) {
TEST_F(DataReductionProxySettingsTest, TestCanUseDataReductionProxy) {
settings_->InitPrefMembers();
// The proxy is disabled initially.
- test_context_->config()->SetStateForTest(false, false, false);
+ test_context_->config()->SetStateForTest(false, false, true);
GURL http_gurl("http://url.com/");
EXPECT_FALSE(settings_->CanUseDataReductionProxy(http_gurl));
@@ -219,7 +219,7 @@ TEST(DataReductionProxySettingsStandaloneTest, TestOnProxyEnabledPrefChange) {
.Build();
// The proxy is enabled initially.
- drp_test_context->config()->SetStateForTest(true, false, false);
+ drp_test_context->config()->SetStateForTest(true, false, true);
drp_test_context->InitSettings();
MockDataReductionProxyService* mock_service =

Powered by Google App Engine
This is Rietveld 408576698