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

Unified Diff: chrome/browser/ui/app_list/app_list_service_unittest.cc

Issue 1128173005: Clean up ProfileManager interface. Base URL: https://chromium.googlesource.com/chromium/src@issue479309
Patch Set: sync 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: chrome/browser/ui/app_list/app_list_service_unittest.cc
diff --git a/chrome/browser/ui/app_list/app_list_service_unittest.cc b/chrome/browser/ui/app_list/app_list_service_unittest.cc
index 4446fb8c68579bf841557d6e5411ec5d6851a5cf..bf27677dad4443ec1e233c859b1fd290085bd86a 100644
--- a/chrome/browser/ui/app_list/app_list_service_unittest.cc
+++ b/chrome/browser/ui/app_list/app_list_service_unittest.cc
@@ -147,8 +147,7 @@ TEST_F(AppListServiceUnitTest, RemovedProfileResetsToInitialProfile) {
EXPECT_EQ("", local_state_->GetString(prefs::kAppListProfile));
base::FilePath initial_profile_path =
user_data_dir_.AppendASCII(chrome::kInitialProfile);
- EXPECT_EQ(initial_profile_path,
- service_->GetProfilePath(profile_store_->GetUserDataDir()));
+ EXPECT_EQ(initial_profile_path, service_->GetProfilePath());
}
TEST_F(AppListServiceUnitTest,
@@ -161,8 +160,7 @@ TEST_F(AppListServiceUnitTest,
EXPECT_EQ("last-used", local_state_->GetString(prefs::kAppListProfile));
base::FilePath last_used_profile_path =
user_data_dir_.AppendASCII("last-used");
- EXPECT_EQ(last_used_profile_path,
- service_->GetProfilePath(profile_store_->GetUserDataDir()));
+ EXPECT_EQ(last_used_profile_path, service_->GetProfilePath());
// For this test, the AppListViewDelegate is not created because the
// app list is never shown, so there is nothing to destroy.
@@ -178,8 +176,7 @@ TEST_F(AppListServiceUnitTest, RefusesToLoadGuestAppListProfile) {
local_state_->SetString(prefs::kProfileLastUsed, "last-used");
base::FilePath last_used_profile_path =
user_data_dir_.AppendASCII("last-used");
- EXPECT_EQ(last_used_profile_path,
- service_->GetProfilePath(profile_store_->GetUserDataDir()));
+ EXPECT_EQ(last_used_profile_path, service_->GetProfilePath());
}
TEST_F(AppListServiceUnitTest, RefusesToLoadGuestLastUsedProfile) {
@@ -190,8 +187,7 @@ TEST_F(AppListServiceUnitTest, RefusesToLoadGuestLastUsedProfile) {
base::FilePath(chrome::kGuestProfileDir).MaybeAsASCII());
base::FilePath initial_profile_path =
user_data_dir_.AppendASCII(chrome::kInitialProfile);
- EXPECT_EQ(initial_profile_path,
- service_->GetProfilePath(profile_store_->GetUserDataDir()));
+ EXPECT_EQ(initial_profile_path, service_->GetProfilePath());
}
TEST_F(AppListServiceUnitTest, SwitchingProfilesPersists) {
@@ -201,11 +197,9 @@ TEST_F(AppListServiceUnitTest, SwitchingProfilesPersists) {
service_->SetProfilePath(profile2_->GetPath());
service_->Show();
EXPECT_EQ(profile2_.get(), service_->showing_for_profile());
- EXPECT_EQ(profile2_->GetPath(),
- service_->GetProfilePath(profile_store_->GetUserDataDir()));
+ EXPECT_EQ(profile2_->GetPath(), service_->GetProfilePath());
service_->SetProfilePath(profile1_->GetPath());
- EXPECT_EQ(profile1_->GetPath(),
- service_->GetProfilePath(profile_store_->GetUserDataDir()));
+ EXPECT_EQ(profile1_->GetPath(), service_->GetProfilePath());
}
TEST_F(AppListServiceUnitTest, EnableViaCommandLineFlag) {
« no previous file with comments | « chrome/browser/ui/app_list/app_list_service_impl_browsertest.cc ('k') | chrome/browser/ui/ash/app_list/app_list_service_ash.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698