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 3db65e9aa8506800906545295e371b71596ff562..75a55b5ae56585aa9cf7c72e809960e622e3421d 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->WaitUntilThreadStartedForTesting(); |
+ |
// 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(); |