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

Unified Diff: chrome/browser/sync/backend_migrator_unittest.cc

Issue 936673002: DCHECK that ProfileSyncService is created on the UI thread. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove snap_. Created 5 years, 10 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 | « no previous file | chrome/browser/sync/profile_sync_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/backend_migrator_unittest.cc
diff --git a/chrome/browser/sync/backend_migrator_unittest.cc b/chrome/browser/sync/backend_migrator_unittest.cc
index 7736e8708e555eb0bdc7189f81ff2c48dc689e50..a5c29f807cde9ab1fc11a6e0b2bfc6cd67623a43 100644
--- a/chrome/browser/sync/backend_migrator_unittest.cc
+++ b/chrome/browser/sync/backend_migrator_unittest.cc
@@ -5,10 +5,12 @@
#include "chrome/browser/sync/backend_migrator.h"
#include "base/message_loop/message_loop.h"
+#include "base/run_loop.h"
#include "base/tracked_objects.h"
#include "chrome/browser/chrome_notification_types.h"
#include "chrome/browser/sync/profile_sync_service_mock.h"
#include "components/sync_driver/data_type_manager_mock.h"
+#include "content/public/test/test_browser_thread_bundle.h"
#include "sync/internal_api/public/base/model_type_test_util.h"
#include "sync/internal_api/public/test/test_user_share.h"
#include "sync/internal_api/public/write_transaction.h"
@@ -84,7 +86,8 @@ class SyncBackendMigratorTest : public testing::Test {
requested_types);
migrator_->OnConfigureDone(result);
}
- message_loop_.RunUntilIdle();
+ base::RunLoop run_loop;
+ run_loop.RunUntilIdle();
}
ProfileSyncService* service() { return &service_; }
@@ -99,8 +102,7 @@ class SyncBackendMigratorTest : public testing::Test {
}
private:
- scoped_ptr<SyncSessionSnapshot> snap_;
- base::MessageLoop message_loop_;
+ content::TestBrowserThreadBundle thread_bundle_;
syncer::ModelTypeSet preferred_types_;
TestingProfile profile_;
NiceMock<ProfileSyncServiceMock> service_;
« no previous file with comments | « no previous file | chrome/browser/sync/profile_sync_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698