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

Unified Diff: chrome/browser/first_run/first_run_browsertest.cc

Issue 147053005: Coarser levels for the SettingsEnforcement field trial. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: constantify trial/group names Created 6 years, 10 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
« no previous file with comments | « no previous file | chrome/browser/prefs/chrome_pref_service_factory.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/first_run/first_run_browsertest.cc
diff --git a/chrome/browser/first_run/first_run_browsertest.cc b/chrome/browser/first_run/first_run_browsertest.cc
index d80dcc02661b5354ddb132b8282ae72c75aff44d..8ef957bbfdd757fa29dece036d947be298a13eed 100644
--- a/chrome/browser/first_run/first_run_browsertest.cc
+++ b/chrome/browser/first_run/first_run_browsertest.cc
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <string>
+
#include "base/command_line.h"
#include "base/files/file_path.h"
#include "base/memory/ref_counted.h"
@@ -12,6 +14,7 @@
#include "chrome/browser/extensions/component_loader.h"
#include "chrome/browser/first_run/first_run.h"
#include "chrome/browser/importer/importer_list.h"
+#include "chrome/browser/prefs/chrome_pref_service_factory.h"
#include "chrome/browser/profiles/profile_manager.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/tabs/tab_strip_model.h"
@@ -247,7 +250,9 @@ class FirstRunMasterPrefsWithTrackedPreferences
virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE {
FirstRunMasterPrefsBrowserTestT::SetUpCommandLine(command_line);
command_line->AppendSwitchASCII(
- switches::kForceFieldTrials, "SettingsEnforcement/" + GetParam() + "/");
+ switches::kForceFieldTrials,
+ std::string(chrome_prefs::internals::kSettingsEnforcementTrialName) +
+ "/" + GetParam() + "/");
}
};
@@ -277,11 +282,13 @@ IN_PROC_BROWSER_TEST_P(FirstRunMasterPrefsWithTrackedPreferences,
EXPECT_TRUE(default_homepage_is_ntp);
}
-INSTANTIATE_TEST_CASE_P(FirstRunMasterPrefsWithTrackedPreferencesInstance,
- FirstRunMasterPrefsWithTrackedPreferences,
- testing::Values("no_enforcement",
- "enforce",
- "enforce_no_seeding",
- "enforce_no_seeding_no_migration"));
+INSTANTIATE_TEST_CASE_P(
+ FirstRunMasterPrefsWithTrackedPreferencesInstance,
+ FirstRunMasterPrefsWithTrackedPreferences,
+ testing::Values(
+ chrome_prefs::internals::kSettingsEnforcementGroupNoEnforcement,
+ chrome_prefs::internals::kSettingsEnforcementGroupEnforceOnload,
+ chrome_prefs::internals::kSettingsEnforcementGroupEnforceAlways));
+
#endif // !defined(OS_CHROMEOS)
« no previous file with comments | « no previous file | chrome/browser/prefs/chrome_pref_service_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698