Index: components/sync/core_impl/attachments/on_disk_attachment_store_unittest.cc |
diff --git a/components/sync/core_impl/attachments/on_disk_attachment_store_unittest.cc b/components/sync/core_impl/attachments/on_disk_attachment_store_unittest.cc |
index ebbc6d16db5b42f11e9e490a00869278ccc1e969..f2483d742d2a1c6679e0df379a6c1fc33e2030a4 100644 |
--- a/components/sync/core_impl/attachments/on_disk_attachment_store_unittest.cc |
+++ b/components/sync/core_impl/attachments/on_disk_attachment_store_unittest.cc |
@@ -48,7 +48,7 @@ class OnDiskAttachmentStoreFactory { |
std::unique_ptr<AttachmentStore> store; |
AttachmentStore::Result result = AttachmentStore::UNSPECIFIED_ERROR; |
store = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &result)); |
base::RunLoop run_loop; |
run_loop.RunUntilIdle(); |
@@ -76,7 +76,7 @@ class OnDiskAttachmentStoreSpecificTest : public testing::Test { |
void SetUp() override { |
ASSERT_TRUE(temp_dir_.CreateUniqueTempDir()); |
- db_path_ = temp_dir_.path().Append(FILE_PATH_LITERAL("leveldb")); |
+ db_path_ = temp_dir_.GetPath().Append(FILE_PATH_LITERAL("leveldb")); |
base::CreateDirectory(db_path_); |
} |
@@ -174,7 +174,7 @@ TEST_F(OnDiskAttachmentStoreSpecificTest, CloseAndReopen) { |
result = AttachmentStore::UNSPECIFIED_ERROR; |
store_ = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &result)); |
RunLoop(); |
EXPECT_EQ(AttachmentStore::SUCCESS, result); |
@@ -195,7 +195,7 @@ TEST_F(OnDiskAttachmentStoreSpecificTest, CloseAndReopen) { |
store_ = nullptr; |
result = AttachmentStore::UNSPECIFIED_ERROR; |
store_ = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &result)); |
RunLoop(); |
EXPECT_EQ(AttachmentStore::SUCCESS, result); |
@@ -222,7 +222,7 @@ TEST_F(OnDiskAttachmentStoreSpecificTest, FailToOpen) { |
AttachmentStore::Result result = AttachmentStore::SUCCESS; |
store_ = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &result)); |
RunLoop(); |
EXPECT_EQ(AttachmentStore::UNSPECIFIED_ERROR, result); |
@@ -236,7 +236,7 @@ TEST_F(OnDiskAttachmentStoreSpecificTest, StoreMetadata) { |
// Open database with AttachmentStore. |
AttachmentStore::Result result = AttachmentStore::UNSPECIFIED_ERROR; |
store_ = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &result)); |
RunLoop(); |
EXPECT_EQ(AttachmentStore::SUCCESS, result); |
@@ -258,7 +258,7 @@ TEST_F(OnDiskAttachmentStoreSpecificTest, StoreMetadata) { |
// AttachmentStore should fail to load. |
result = AttachmentStore::SUCCESS; |
store_ = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &result)); |
RunLoop(); |
EXPECT_EQ(AttachmentStore::UNSPECIFIED_ERROR, result); |
@@ -269,7 +269,7 @@ TEST_F(OnDiskAttachmentStoreSpecificTest, StoreMetadata) { |
// AttachmentStore should fail to load. |
result = AttachmentStore::SUCCESS; |
store_ = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &result)); |
RunLoop(); |
EXPECT_EQ(AttachmentStore::UNSPECIFIED_ERROR, result); |
@@ -281,7 +281,7 @@ TEST_F(OnDiskAttachmentStoreSpecificTest, RecordMetadata) { |
// Create attachment store. |
AttachmentStore::Result create_result = AttachmentStore::UNSPECIFIED_ERROR; |
store_ = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &create_result)); |
// Write two attachments. |
@@ -322,7 +322,7 @@ TEST_F(OnDiskAttachmentStoreSpecificTest, MismatchedCrcInStore) { |
// Create attachment store. |
AttachmentStore::Result create_result = AttachmentStore::UNSPECIFIED_ERROR; |
store_ = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &create_result)); |
// Write attachment with incorrect crc32c. |
@@ -362,7 +362,7 @@ TEST_F(OnDiskAttachmentStoreSpecificTest, MismatchedCrcInId) { |
// Create attachment store. |
AttachmentStore::Result create_result = AttachmentStore::UNSPECIFIED_ERROR; |
store_ = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &create_result)); |
AttachmentStore::Result write_result = AttachmentStore::UNSPECIFIED_ERROR; |
@@ -404,7 +404,7 @@ TEST_F(OnDiskAttachmentStoreSpecificTest, OpsAfterInitializationFailed) { |
AttachmentStore::Result create_result = AttachmentStore::SUCCESS; |
store_ = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &create_result)); |
// Reading from uninitialized store should result in |
@@ -454,7 +454,7 @@ TEST_F(OnDiskAttachmentStoreSpecificTest, ReadMetadataWithUnexpectedRecord) { |
// Create attachment store. |
AttachmentStore::Result create_result = AttachmentStore::UNSPECIFIED_ERROR; |
store_ = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &create_result)); |
// Read all metadata. Should be getting no error and zero entries. |
@@ -506,7 +506,7 @@ TEST_F(OnDiskAttachmentStoreSpecificTest, ReadMetadataWithUnexpectedRecord) { |
create_result = AttachmentStore::UNSPECIFIED_ERROR; |
metadata_result = AttachmentStore::UNSPECIFIED_ERROR; |
store_ = AttachmentStore::CreateOnDiskStore( |
- temp_dir_.path(), base::ThreadTaskRunnerHandle::Get(), |
+ temp_dir_.GetPath(), base::ThreadTaskRunnerHandle::Get(), |
base::Bind(&AttachmentStoreCreated, &create_result)); |
// Read all metadata back. We should be getting a failure and |