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

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

Issue 1933653004: Reset the Lo-Fi main frame state when there is a new main frame request (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comments Created 4 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 092c48c2006ab65776948917c59c2d1b663df82b..b07813e337d6072ab333ae2a00e2469b56d7025a 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
@@ -309,31 +309,10 @@ TEST_F(DataReductionProxySettingsTest, TestSetDataReductionProxyEnabled) {
settings_->SetDataReductionProxyEnabled(false);
test_context_->RunUntilIdle();
CheckDataReductionProxySyntheticTrial(false);
- CheckDataReductionProxyLoFiSyntheticTrial(false);
ExpectSetProxyPrefs(true, false);
settings->SetDataReductionProxyEnabled(true);
CheckDataReductionProxySyntheticTrial(true);
- CheckDataReductionProxyLoFiSyntheticTrial(true);
-}
-
-TEST_F(DataReductionProxySettingsTest, TestEnableLoFiSyntheticTrial) {
- MockSettings* settings = static_cast<MockSettings*>(settings_.get());
- EXPECT_CALL(*settings, RecordStartupState(PROXY_ENABLED));
- test_context_->SetDataReductionProxyEnabled(true);
- InitDataReductionProxy(true);
-
- // The Lo-Fi field trial will be set to "Disabled" until the first main frame
- // request with Lo-Fi active.
- CheckDataReductionProxyLoFiSyntheticTrial(false);
-
- // Turn Lo-Fi on.
- settings->SetLoFiModeActiveOnMainFrame(true);
- CheckDataReductionProxyLoFiSyntheticTrial(true);
-
- // Now turn it off.
- settings->SetLoFiModeActiveOnMainFrame(false);
- CheckDataReductionProxyLoFiSyntheticTrial(false);
}
TEST_F(DataReductionProxySettingsTest, TestLoFiImplicitOptOutClicksPerSession) {

Powered by Google App Engine
This is Rietveld 408576698