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

Unified Diff: chrome/browser/chromeos/file_manager/path_util_unittest.cc

Issue 442043002: ProfileManager doesn't depend on "--login-profile" switch. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 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/chromeos/file_manager/path_util_unittest.cc
diff --git a/chrome/browser/chromeos/file_manager/path_util_unittest.cc b/chrome/browser/chromeos/file_manager/path_util_unittest.cc
index c3bfbed071c256d0110063e32ed7844402fc2dcc..0a45f098b99a6ba6e94329e16d73076ce5c55cbb 100644
--- a/chrome/browser/chromeos/file_manager/path_util_unittest.cc
+++ b/chrome/browser/chromeos/file_manager/path_util_unittest.cc
@@ -6,7 +6,7 @@
#include "base/files/file_path.h"
#include "chrome/browser/chromeos/drive/file_system_util.h"
-#include "chrome/common/chrome_constants.h"
+#include "chrome/browser/chromeos/profiles/profile_helper.h"
#include "chrome/test/base/testing_browser_process.h"
#include "chrome/test/base/testing_profile.h"
#include "chrome/test/base/testing_profile_manager.h"
@@ -27,8 +27,7 @@ class ProfileRelatedTest : public testing::Test {
}
Profile* CreateProfileWithName(const std::string& name) {
- return testing_profile_manager_.CreateTestingProfile(
- chrome::kProfileDirPrefix + name);
+ return testing_profile_manager_.CreateTestingProfile(name);
}
private:
@@ -70,10 +69,13 @@ TEST(FileManagerPathUtilTest, MultiProfileDownloadsFolderMigration) {
}
TEST_F(ProfileRelatedTest, MultiProfileDriveFolderMigration) {
- Profile* profile = CreateProfileWithName("hash");
+ Profile* profile = CreateProfileWithName("user1");
const base::FilePath kDrive = drive::util::GetDriveMountPointPath(profile);
- ASSERT_EQ(base::FilePath::FromUTF8Unsafe("/special/drive-hash"), kDrive);
+ const std::string user_id_hash =
+ chromeos::ProfileHelper::GetUserIdHashByUserIdForTesting("user1");
+ ASSERT_EQ(base::FilePath::FromUTF8Unsafe("/special/drive-" + user_id_hash),
+ kDrive);
base::FilePath path;

Powered by Google App Engine
This is Rietveld 408576698