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

Unified Diff: chrome/browser/subresource_filter/subresource_filter_unittest.cc

Issue 2844063002: Add support for multiple simultaneous subresource_filter::Configurations. (Closed)
Patch Set: Rebase. Created 3 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: chrome/browser/subresource_filter/subresource_filter_unittest.cc
diff --git a/chrome/browser/subresource_filter/subresource_filter_unittest.cc b/chrome/browser/subresource_filter/subresource_filter_unittest.cc
index 16898a473b1a1e5cdf925d2c09d106630c5d276c..588dfc1b579f4fdbd201dc9a2c077b3e70192210 100644
--- a/chrome/browser/subresource_filter/subresource_filter_unittest.cc
+++ b/chrome/browser/subresource_filter/subresource_filter_unittest.cc
@@ -36,6 +36,7 @@
namespace {
using subresource_filter::testing::ScopedSubresourceFilterConfigurator;
+using subresource_filter::testing::ScopedSubresourceFilterFeatureToggle;
} // namespace
// End to end unit test harness of (most of) the browser process portions of the
@@ -51,7 +52,9 @@ class SubresourceFilterTest : public ChromeRenderViewHostTestHarness {
AfterStartupTaskUtils::SetBrowserStartupIsCompleteForTesting();
// Ensure correct features.
- scoped_feature_list_.InitFromCommandLine("SafeBrowsingV4OnlyEnabled", "");
+ scoped_feature_toggle_.ResetSubresourceFilterState(
+ base::FeatureList::OVERRIDE_ENABLE_FEATURE,
+ "SafeBrowsingV4OnlyEnabled" /* additional_features */);
scoped_configuration_.ResetConfiguration(subresource_filter::Configuration(
subresource_filter::ActivationLevel::ENABLED,
subresource_filter::ActivationScope::ACTIVATION_LIST,
@@ -154,7 +157,7 @@ class SubresourceFilterTest : public ChromeRenderViewHostTestHarness {
private:
base::ScopedTempDir ruleset_service_dir_;
TestingPrefServiceSimple pref_service_;
- base::test::ScopedFeatureList scoped_feature_list_;
+ ScopedSubresourceFilterFeatureToggle scoped_feature_toggle_;
ScopedSubresourceFilterConfigurator scoped_configuration_;
scoped_refptr<FakeSafeBrowsingDatabaseManager> fake_safe_browsing_database_;

Powered by Google App Engine
This is Rietveld 408576698