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

Unified Diff: chrome/browser/sync_file_system/syncable_file_system_util_unittest.cc

Issue 23578026: Use SNAPSHOT sync mode for LocalSync (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: addressed comments Created 7 years, 3 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/sync_file_system/syncable_file_system_util_unittest.cc
diff --git a/chrome/browser/sync_file_system/syncable_file_system_util_unittest.cc b/chrome/browser/sync_file_system/syncable_file_system_util_unittest.cc
index 583bfe86c46dd8d5278d714a1def3e739605ad68..82bcb7f7c7732a663c9cf980acebb2cf8c7e03f9 100644
--- a/chrome/browser/sync_file_system/syncable_file_system_util_unittest.cc
+++ b/chrome/browser/sync_file_system/syncable_file_system_util_unittest.cc
@@ -4,6 +4,7 @@
#include "chrome/browser/sync_file_system/syncable_file_system_util.h"
+#include "base/files/scoped_temp_dir.h"
#include "base/logging.h"
#include "base/message_loop/message_loop.h"
#include "base/message_loop/message_loop_proxy.h"
@@ -115,16 +116,20 @@ TEST(SyncableFileSystemUtilTest, SerializeBeforeOpenFileSystem) {
ScopedEnableSyncFSDirectoryOperation enable_directory_operation_;
const std::string serialized = kSyncableFileSystemRootURI +
CreateNormalizedFilePath(kPath).AsUTF8Unsafe();
+ base::ScopedTempDir dir;
FileSystemURL deserialized;
base::MessageLoop message_loop;
+ ASSERT_TRUE(dir.CreateUniqueTempDir());
+
// Setting up a full syncable filesystem environment.
CannedSyncableFileSystem file_system(GURL(kOrigin),
base::MessageLoopProxy::current().get(),
base::MessageLoopProxy::current().get());
file_system.SetUp();
scoped_refptr<LocalFileSyncContext> sync_context =
- new LocalFileSyncContext(base::MessageLoopProxy::current().get(),
+ new LocalFileSyncContext(dir.path(),
+ base::MessageLoopProxy::current().get(),
base::MessageLoopProxy::current().get());
// Before calling initialization we would not be able to get a valid

Powered by Google App Engine
This is Rietveld 408576698