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

Unified Diff: chrome/browser/chromeos/drive/file_system_util_unittest.cc

Issue 442383002: Move storage-related files from webkit/ to new top-level directory storage/ (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/drive/file_system_util_unittest.cc
diff --git a/chrome/browser/chromeos/drive/file_system_util_unittest.cc b/chrome/browser/chromeos/drive/file_system_util_unittest.cc
index b5873f8977f5511b4c2ed6dd5a22b6f8d7cc6a9e..7760e5cef92c93e7e1099fa5cece143856e7be2f 100644
--- a/chrome/browser/chromeos/drive/file_system_util_unittest.cc
+++ b/chrome/browser/chromeos/drive/file_system_util_unittest.cc
@@ -17,11 +17,11 @@
#include "content/public/test/test_file_system_options.h"
#include "google_apis/drive/test_util.h"
#include "testing/gtest/include/gtest/gtest.h"
-#include "webkit/browser/fileapi/external_mount_points.h"
-#include "webkit/browser/fileapi/file_system_backend.h"
-#include "webkit/browser/fileapi/file_system_context.h"
-#include "webkit/browser/fileapi/file_system_url.h"
-#include "webkit/browser/fileapi/isolated_context.h"
+#include "storage/browser/fileapi/external_mount_points.h"
+#include "storage/browser/fileapi/file_system_backend.h"
+#include "storage/browser/fileapi/file_system_context.h"
+#include "storage/browser/fileapi/file_system_url.h"
+#include "storage/browser/fileapi/isolated_context.h"
namespace drive {
namespace util {
@@ -143,28 +143,27 @@ TEST(FileSystemUtilTest, ExtractDrivePathFromFileSystemUrl) {
ASSERT_TRUE(temp_dir_.CreateUniqueTempDir());
base::MessageLoop message_loop;
- scoped_refptr<fileapi::ExternalMountPoints> mount_points =
- fileapi::ExternalMountPoints::CreateRefCounted();
- scoped_refptr<fileapi::FileSystemContext> context(
- new fileapi::FileSystemContext(
+ scoped_refptr<storage::ExternalMountPoints> mount_points =
+ storage::ExternalMountPoints::CreateRefCounted();
+ scoped_refptr<storage::FileSystemContext> context(
+ new storage::FileSystemContext(
base::MessageLoopProxy::current().get(),
base::MessageLoopProxy::current().get(),
mount_points.get(),
NULL, // special_storage_policy
NULL, // quota_manager_proxy,
- ScopedVector<fileapi::FileSystemBackend>(),
- std::vector<fileapi::URLRequestAutoMountHandler>(),
+ ScopedVector<storage::FileSystemBackend>(),
+ std::vector<storage::URLRequestAutoMountHandler>(),
temp_dir_.path(), // partition_path
content::CreateAllowFileAccessOptions()));
// Type:"external" + virtual_path:"drive/foo/bar" resolves to "drive/foo/bar".
const std::string& drive_mount_name =
GetDriveMountPointPath(&profile).BaseName().AsUTF8Unsafe();
- mount_points->RegisterFileSystem(
- drive_mount_name,
- fileapi::kFileSystemTypeDrive,
- fileapi::FileSystemMountOption(),
- GetDriveMountPointPath(&profile));
+ mount_points->RegisterFileSystem(drive_mount_name,
+ storage::kFileSystemTypeDrive,
+ storage::FileSystemMountOption(),
+ GetDriveMountPointPath(&profile));
EXPECT_EQ(
base::FilePath::FromUTF8Unsafe("drive/foo/bar"),
ExtractDrivePathFromFileSystemUrl(context->CrackURL(GURL(
@@ -173,22 +172,20 @@ TEST(FileSystemUtilTest, ExtractDrivePathFromFileSystemUrl) {
// Virtual mount name should not affect the extracted path.
mount_points->RevokeFileSystem(drive_mount_name);
- mount_points->RegisterFileSystem(
- "drive2",
- fileapi::kFileSystemTypeDrive,
- fileapi::FileSystemMountOption(),
- GetDriveMountPointPath(&profile));
+ mount_points->RegisterFileSystem("drive2",
+ storage::kFileSystemTypeDrive,
+ storage::FileSystemMountOption(),
+ GetDriveMountPointPath(&profile));
EXPECT_EQ(
base::FilePath::FromUTF8Unsafe("drive/foo/bar"),
ExtractDrivePathFromFileSystemUrl(context->CrackURL(GURL(
"filesystem:chrome-extension://dummy-id/external/drive2/foo/bar"))));
// Type:"external" + virtual_path:"Downloads/foo" is not a Drive path.
- mount_points->RegisterFileSystem(
- "Downloads",
- fileapi::kFileSystemTypeNativeLocal,
- fileapi::FileSystemMountOption(),
- temp_dir_.path());
+ mount_points->RegisterFileSystem("Downloads",
+ storage::kFileSystemTypeNativeLocal,
+ storage::FileSystemMountOption(),
+ temp_dir_.path());
EXPECT_EQ(
base::FilePath(),
ExtractDrivePathFromFileSystemUrl(context->CrackURL(GURL(
@@ -197,8 +194,8 @@ TEST(FileSystemUtilTest, ExtractDrivePathFromFileSystemUrl) {
// Type:"isolated" + virtual_path:"isolated_id/name" mapped on a Drive path.
std::string isolated_name;
std::string isolated_id =
- fileapi::IsolatedContext::GetInstance()->RegisterFileSystemForPath(
- fileapi::kFileSystemTypeNativeForPlatformApp,
+ storage::IsolatedContext::GetInstance()->RegisterFileSystemForPath(
+ storage::kFileSystemTypeNativeForPlatformApp,
std::string(),
GetDriveMountPointPath(&profile).AppendASCII("bar/buz"),
&isolated_name);
« no previous file with comments | « chrome/browser/chromeos/drive/file_system_util.cc ('k') | chrome/browser/chromeos/drive/file_task_executor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698