OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/platform_util.h" | 5 #include "chrome/browser/platform_util.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/files/file_util.h" | 9 #include "base/files/file_util.h" |
10 #include "base/files/scoped_temp_dir.h" | 10 #include "base/files/scoped_temp_dir.h" |
| 11 #include "base/macros.h" |
11 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
12 #include "base/run_loop.h" | 13 #include "base/run_loop.h" |
| 14 #include "build/build_config.h" |
13 #include "chrome/browser/platform_util_internal.h" | 15 #include "chrome/browser/platform_util_internal.h" |
14 #include "testing/gtest/include/gtest/gtest.h" | 16 #include "testing/gtest/include/gtest/gtest.h" |
15 | 17 |
16 #if defined(OS_CHROMEOS) | 18 #if defined(OS_CHROMEOS) |
17 #include "base/json/json_string_value_serializer.h" | 19 #include "base/json/json_string_value_serializer.h" |
18 #include "base/values.h" | 20 #include "base/values.h" |
19 #include "chrome/browser/chrome_content_browser_client.h" | 21 #include "chrome/browser/chrome_content_browser_client.h" |
20 #include "chrome/browser/chromeos/file_manager/app_id.h" | 22 #include "chrome/browser/chromeos/file_manager/app_id.h" |
21 #include "chrome/browser/chromeos/fileapi/file_system_backend.h" | 23 #include "chrome/browser/chromeos/fileapi/file_system_backend.h" |
22 #include "chrome/browser/extensions/extension_special_storage_policy.h" | 24 #include "chrome/browser/extensions/extension_special_storage_policy.h" |
(...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
283 TEST_F(PlatformUtilPosixTest, OpenFolderWithPosixSymlinks) { | 285 TEST_F(PlatformUtilPosixTest, OpenFolderWithPosixSymlinks) { |
284 EXPECT_EQ(OPEN_SUCCEEDED, CallOpenItem(symlink_to_folder_, OPEN_FOLDER)); | 286 EXPECT_EQ(OPEN_SUCCEEDED, CallOpenItem(symlink_to_folder_, OPEN_FOLDER)); |
285 EXPECT_EQ(OPEN_FAILED_INVALID_TYPE, | 287 EXPECT_EQ(OPEN_FAILED_INVALID_TYPE, |
286 CallOpenItem(symlink_to_file_, OPEN_FOLDER)); | 288 CallOpenItem(symlink_to_file_, OPEN_FOLDER)); |
287 EXPECT_EQ(OPEN_FAILED_PATH_NOT_FOUND, | 289 EXPECT_EQ(OPEN_FAILED_PATH_NOT_FOUND, |
288 CallOpenItem(symlink_to_nowhere_, OPEN_FOLDER)); | 290 CallOpenItem(symlink_to_nowhere_, OPEN_FOLDER)); |
289 } | 291 } |
290 #endif // OS_POSIX && !OS_CHROMEOS | 292 #endif // OS_POSIX && !OS_CHROMEOS |
291 | 293 |
292 } // namespace platform_util | 294 } // namespace platform_util |
OLD | NEW |