Chromium Code Reviews| Index: components/browser_sync/profile_sync_service.cc |
| diff --git a/components/browser_sync/profile_sync_service.cc b/components/browser_sync/profile_sync_service.cc |
| index 2909868bc33e3addeee8a618ad28c941de3a26e5..a099077ecaf51ca0cf17f631ad834141ba128414 100644 |
| --- a/components/browser_sync/profile_sync_service.cc |
| +++ b/components/browser_sync/profile_sync_service.cc |
| @@ -21,6 +21,7 @@ |
| #include "base/memory/ref_counted.h" |
| #include "base/metrics/histogram.h" |
| #include "base/profiler/scoped_tracker.h" |
| +#include "base/run_loop.h" |
|
pavely
2017/03/07 07:26:16
You shouldn't need RunLoop in this file.
|
| #include "base/single_thread_task_runner.h" |
| #include "base/strings/stringprintf.h" |
| #include "base/threading/thread_restrictions.h" |
| @@ -1386,6 +1387,7 @@ bool ProfileSyncService::IsFirstSetupInProgress() const { |
| std::unique_ptr<syncer::SyncSetupInProgressHandle> |
| ProfileSyncService::GetSetupInProgressHandle() { |
| DCHECK(thread_checker_.CalledOnValidThread()); |
| + |
|
pavely
2017/03/07 07:26:16
Doe extra line make function more readable? Coding
|
| if (++outstanding_setup_in_progress_handles_ == 1) { |
| DCHECK(!startup_controller_->IsSetupInProgress()); |
| startup_controller_->SetSetupInProgress(true); |
| @@ -2426,4 +2428,10 @@ void ProfileSyncService::OnSetupInProgressHandleDestroyed() { |
| NotifyObservers(); |
| } |
| +void ProfileSyncService::ClearServerDataForTest(const base::Closure& callback) { |
|
pavely
2017/03/07 07:26:16
I would put this function after RefreshTypesForTes
|
| + DCHECK(thread_checker_.CalledOnValidThread()); |
| + engine_->StartConfiguration(); |
| + engine_->ClearServerData(callback); |
| +} |
| + |
| } // namespace browser_sync |