OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/chromeos/file_manager/path_util.h" | 5 #include "chrome/browser/chromeos/file_manager/path_util.h" |
6 | 6 |
7 #include "base/files/file_path.h" | 7 #include "base/files/file_path.h" |
8 #include "chrome/browser/chromeos/drive/file_system_util.h" | 8 #include "chrome/browser/chromeos/drive/file_system_util.h" |
9 #include "chrome/browser/chromeos/profiles/profile_helper.h" | 9 #include "chrome/browser/chromeos/profiles/profile_helper.h" |
10 #include "chrome/test/base/testing_browser_process.h" | 10 #include "chrome/test/base/testing_browser_process.h" |
11 #include "chrome/test/base/testing_profile.h" | 11 #include "chrome/test/base/testing_profile.h" |
12 #include "chrome/test/base/testing_profile_manager.h" | 12 #include "chrome/test/base/testing_profile_manager.h" |
13 #include "testing/gtest/include/gtest/gtest.h" | 13 #include "testing/gtest/include/gtest/gtest.h" |
14 | 14 |
15 namespace file_manager { | 15 namespace file_manager { |
16 namespace util { | 16 namespace util { |
17 namespace { | 17 namespace { |
18 | 18 |
19 class ProfileRelatedTest : public testing::Test { | 19 class ProfileRelatedTest : public testing::Test { |
20 protected: | 20 protected: |
21 ProfileRelatedTest() | 21 ProfileRelatedTest() |
22 : testing_profile_manager_(TestingBrowserProcess::GetGlobal()) { | 22 : testing_profile_manager_(TestingBrowserProcess::GetGlobal()) { |
23 } | 23 } |
24 | 24 |
25 virtual void SetUp() OVERRIDE { | 25 virtual void SetUp() override { |
26 ASSERT_TRUE(testing_profile_manager_.SetUp()); | 26 ASSERT_TRUE(testing_profile_manager_.SetUp()); |
27 } | 27 } |
28 | 28 |
29 Profile* CreateProfileWithName(const std::string& name) { | 29 Profile* CreateProfileWithName(const std::string& name) { |
30 return testing_profile_manager_.CreateTestingProfile(name); | 30 return testing_profile_manager_.CreateTestingProfile(name); |
31 } | 31 } |
32 | 32 |
33 private: | 33 private: |
34 TestingProfileManager testing_profile_manager_; | 34 TestingProfileManager testing_profile_manager_; |
35 }; | 35 }; |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
100 // Only the "/special/drive" path is converted. | 100 // Only the "/special/drive" path is converted. |
101 EXPECT_FALSE(MigratePathFromOldFormat( | 101 EXPECT_FALSE(MigratePathFromOldFormat( |
102 profile, | 102 profile, |
103 base::FilePath::FromUTF8Unsafe("/special/notdrive"), | 103 base::FilePath::FromUTF8Unsafe("/special/notdrive"), |
104 &path)); | 104 &path)); |
105 } | 105 } |
106 | 106 |
107 } // namespace | 107 } // namespace |
108 } // namespace util | 108 } // namespace util |
109 } // namespace file_manager | 109 } // namespace file_manager |
OLD | NEW |