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

Unified Diff: chrome/test/sync/engine/test_directory_setter_upper.cc

Issue 214033: Use chrome/base synchronization primitives and threads instead of... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 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
« no previous file with comments | « chrome/test/sync/engine/test_directory_setter_upper.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/sync/engine/test_directory_setter_upper.cc
===================================================================
--- chrome/test/sync/engine/test_directory_setter_upper.cc (revision 27087)
+++ chrome/test/sync/engine/test_directory_setter_upper.cc (working copy)
@@ -20,12 +20,15 @@
TestDirectorySetterUpper::~TestDirectorySetterUpper() {}
-void TestDirectorySetterUpper::SetUp() {
+void TestDirectorySetterUpper::Init() {
PathString test_data_dir_ = PSTR(".");
manager_.reset(new DirectoryManager(test_data_dir_));
file_path_ = manager_->GetSyncDataDatabasePath();
PathRemove(file_path_.c_str());
+}
+void TestDirectorySetterUpper::SetUp() {
+ Init();
ASSERT_TRUE(manager()->Open(name()));
}
@@ -64,4 +67,19 @@
}
}
+void ManuallyOpenedTestDirectorySetterUpper::SetUp() {
+ Init();
+}
+
+void ManuallyOpenedTestDirectorySetterUpper::Open() {
+ ASSERT_TRUE(manager()->Open(name()));
+ was_opened_ = true;
+}
+
+void ManuallyOpenedTestDirectorySetterUpper::TearDown() {
+ if (was_opened_) {
+ TestDirectorySetterUpper::TearDown();
+ }
+}
+
} // namespace browser_sync
« no previous file with comments | « chrome/test/sync/engine/test_directory_setter_upper.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698