| 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 "chrome/browser/sync/test/integration/sync_test.h" | 5 #include "chrome/browser/sync/test/integration/sync_test.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <limits> | 10 #include <limits> |
| (...skipping 600 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 611 new P2PSyncRefresher(GetProfile(i), clients_[i]->service()); | 611 new P2PSyncRefresher(GetProfile(i), clients_[i]->service()); |
| 612 } | 612 } |
| 613 | 613 |
| 614 // OneClickSigninSyncStarter observer is created with a real user sign in. | 614 // OneClickSigninSyncStarter observer is created with a real user sign in. |
| 615 // It is deleted on certain conditions which are not satisfied by our tests, | 615 // It is deleted on certain conditions which are not satisfied by our tests, |
| 616 // and this causes the SigninTracker observer to stay hanging at shutdown. | 616 // and this causes the SigninTracker observer to stay hanging at shutdown. |
| 617 // Calling LoginUIService::SyncConfirmationUIClosed forces the observer to | 617 // Calling LoginUIService::SyncConfirmationUIClosed forces the observer to |
| 618 // be removed. http://crbug.com/484388 | 618 // be removed. http://crbug.com/484388 |
| 619 for (int i = 0; i < num_clients_; ++i) { | 619 for (int i = 0; i < num_clients_; ++i) { |
| 620 LoginUIServiceFactory::GetForProfile(GetProfile(i))-> | 620 LoginUIServiceFactory::GetForProfile(GetProfile(i))-> |
| 621 SyncConfirmationUIClosed(false /* configure_sync_first */); | 621 SyncConfirmationUIClosed(LoginUIService::SYNC_WITH_DEFAULT_SETTINGS); |
| 622 } | 622 } |
| 623 } | 623 } |
| 624 | 624 |
| 625 return true; | 625 return true; |
| 626 } | 626 } |
| 627 | 627 |
| 628 void SyncTest::TearDownOnMainThread() { | 628 void SyncTest::TearDownOnMainThread() { |
| 629 for (size_t i = 0; i < clients_.size(); ++i) { | 629 for (size_t i = 0; i < clients_.size(); ++i) { |
| 630 clients_[i]->service()->RequestStop(ProfileSyncService::CLEAR_DATA); | 630 clients_[i]->service()->RequestStop(ProfileSyncService::CLEAR_DATA); |
| 631 } | 631 } |
| (...skipping 466 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1098 | 1098 |
| 1099 void SyncTest::TriggerSyncForModelTypes(int index, | 1099 void SyncTest::TriggerSyncForModelTypes(int index, |
| 1100 syncer::ModelTypeSet model_types) { | 1100 syncer::ModelTypeSet model_types) { |
| 1101 GetSyncService(index)->TriggerRefresh(model_types); | 1101 GetSyncService(index)->TriggerRefresh(model_types); |
| 1102 } | 1102 } |
| 1103 | 1103 |
| 1104 void SyncTest::SetPreexistingPreferencesFileContents( | 1104 void SyncTest::SetPreexistingPreferencesFileContents( |
| 1105 const std::string& contents) { | 1105 const std::string& contents) { |
| 1106 preexisting_preferences_file_contents_ = contents; | 1106 preexisting_preferences_file_contents_ = contents; |
| 1107 } | 1107 } |
| OLD | NEW |