| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "components/browser_sync/profile_sync_service.h" | 5 #include "components/browser_sync/profile_sync_service.h" |
| 6 | 6 |
| 7 #include "base/files/file_util.h" | 7 #include "base/files/file_util.h" |
| 8 #include "base/memory/ptr_util.h" | 8 #include "base/memory/ptr_util.h" |
| 9 #include "base/message_loop/message_loop.h" |
| 9 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
| 10 #include "base/threading/thread_task_runner_handle.h" | 11 #include "base/threading/thread_task_runner_handle.h" |
| 11 #include "components/browser_sync/profile_sync_test_util.h" | 12 #include "components/browser_sync/profile_sync_test_util.h" |
| 12 #include "components/prefs/pref_service.h" | 13 #include "components/prefs/pref_service.h" |
| 13 #include "components/signin/core/browser/account_tracker_service.h" | 14 #include "components/signin/core/browser/account_tracker_service.h" |
| 14 #include "components/signin/core/browser/fake_profile_oauth2_token_service.h" | 15 #include "components/signin/core/browser/fake_profile_oauth2_token_service.h" |
| 15 #include "components/signin/core/browser/profile_oauth2_token_service.h" | 16 #include "components/signin/core/browser/profile_oauth2_token_service.h" |
| 16 #include "components/signin/core/browser/signin_manager.h" | 17 #include "components/signin/core/browser/signin_manager.h" |
| 17 #include "components/signin/core/common/signin_pref_names.h" | 18 #include "components/signin/core/common/signin_pref_names.h" |
| 18 #include "components/sync/base/pref_names.h" | 19 #include "components/sync/base/pref_names.h" |
| (...skipping 454 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 473 EXPECT_CALL(observer_, OnStateChanged(_)).Times(AnyNumber()); | 474 EXPECT_CALL(observer_, OnStateChanged(_)).Times(AnyNumber()); |
| 474 sync_service_->Initialize(); | 475 sync_service_->Initialize(); |
| 475 | 476 |
| 476 auto sync_blocker = sync_service_->GetSetupInProgressHandle(); | 477 auto sync_blocker = sync_service_->GetSetupInProgressHandle(); |
| 477 IssueTestTokens(account_id); | 478 IssueTestTokens(account_id); |
| 478 sync_blocker.reset(); | 479 sync_blocker.reset(); |
| 479 EXPECT_FALSE(sync_service_->IsSyncActive()); | 480 EXPECT_FALSE(sync_service_->IsSyncActive()); |
| 480 } | 481 } |
| 481 | 482 |
| 482 } // namespace browser_sync | 483 } // namespace browser_sync |
| OLD | NEW |