Multi-profile flag cleanup.
Rebased version of https://codereview.chromium.org/287083003/
BUG=364604, 351655
TEST=existing tests
TBR=sky,zelidrag
Review URL: https://codereview.chromium.org/294033002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@271720 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/chrome/browser/profiles/profile_manager_unittest.cc b/chrome/browser/profiles/profile_manager_unittest.cc
index fb040c1..a0f1660 100644
--- a/chrome/browser/profiles/profile_manager_unittest.cc
+++ b/chrome/browser/profiles/profile_manager_unittest.cc
@@ -378,8 +378,7 @@
}
};
-class ProfileManagerGuestTest : public ProfileManagerTest,
- public testing::WithParamInterface<bool> {
+class ProfileManagerGuestTest : public ProfileManagerTest {
protected:
virtual void SetUp() {
// Create a new temporary directory, and store the path
@@ -389,17 +388,13 @@
#if defined(OS_CHROMEOS)
CommandLine* cl = CommandLine::ForCurrentProcess();
- if (GetParam())
- cl->AppendSwitch(switches::kMultiProfiles);
-
+ // This switch is needed to skip non-test specific behavior in
+ // ProfileManager (accessing DBusThreadManager).
cl->AppendSwitch(switches::kTestType);
- if (profiles::IsMultipleProfilesEnabled()) {
- cl->AppendSwitchASCII(chromeos::switches::kLoginProfile,
- std::string(chrome::kProfileDirPrefix) +
- chromeos::UserManager::kGuestUserName);
- } else {
- cl->AppendSwitchASCII(chromeos::switches::kLoginProfile, "user");
- }
+
+ cl->AppendSwitchASCII(chromeos::switches::kLoginProfile,
+ std::string(chrome::kProfileDirPrefix) +
+ chromeos::UserManager::kGuestUserName);
cl->AppendSwitch(chromeos::switches::kGuestSession);
cl->AppendSwitch(::switches::kIncognito);
@@ -411,11 +406,7 @@
}
};
-INSTANTIATE_TEST_CASE_P(ProfileManagerGuestTestInstantiation,
- ProfileManagerGuestTest,
- testing::Bool());
-
-TEST_P(ProfileManagerGuestTest, GetLastUsedProfileAllowedByPolicy) {
+TEST_F(ProfileManagerGuestTest, GetLastUsedProfileAllowedByPolicy) {
ProfileManager* profile_manager = g_browser_process->profile_manager();
ASSERT_TRUE(profile_manager);
@@ -425,7 +416,7 @@
}
#if defined(OS_CHROMEOS)
-TEST_P(ProfileManagerGuestTest, GuestProfileIngonito) {
+TEST_F(ProfileManagerGuestTest, GuestProfileIngonito) {
Profile* primary_profile = ProfileManager::GetPrimaryUserProfile();
EXPECT_TRUE(primary_profile->IsOffTheRecord());