Index: chrome/browser/sync/glue/sync_backend_registrar_unittest.cc |
diff --git a/chrome/browser/sync/glue/sync_backend_registrar_unittest.cc b/chrome/browser/sync/glue/sync_backend_registrar_unittest.cc |
index 1129bbffb8272ef42e504bda7cbe9e70afeef80f..e412dea32d36112180dfead2d52e93e9dd8d629a 100644 |
--- a/chrome/browser/sync/glue/sync_backend_registrar_unittest.cc |
+++ b/chrome/browser/sync/glue/sync_backend_registrar_unittest.cc |
@@ -336,6 +336,9 @@ TEST_F(SyncBackendRegistrarShutdownTest, BlockingShutdown) { |
base::Bind(&SyncBackendRegistrar::Shutdown, |
base::Unretained(registrar.release()))); |
+ // Make sure the thread starts running. |
+ sync_thread->WaitUntilThreadStarted(); |
+ |
// The test verifies that the sync thread doesn't block because |
// of the blocked DB thread and can finish the shutdown. |
sync_thread->message_loop()->RunUntilIdle(); |