OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // Unit tests for the SyncApi. Note that a lot of the underlying | 5 // Unit tests for the SyncApi. Note that a lot of the underlying |
6 // functionality is provided by the Syncable layer, which has its own | 6 // functionality is provided by the Syncable layer, which has its own |
7 // unit tests. We'll test SyncApi specific things in this harness. | 7 // unit tests. We'll test SyncApi specific things in this harness. |
8 | 8 |
9 #include <map> | 9 #include <map> |
10 | 10 |
(...skipping 599 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
610 const SyncManager::ChangeRecord*, | 610 const SyncManager::ChangeRecord*, |
611 int)); // NOLINT | 611 int)); // NOLINT |
612 MOCK_METHOD1(OnChangesComplete, void(ModelType)); // NOLINT | 612 MOCK_METHOD1(OnChangesComplete, void(ModelType)); // NOLINT |
613 MOCK_METHOD1(OnSyncCycleCompleted, | 613 MOCK_METHOD1(OnSyncCycleCompleted, |
614 void(const SyncSessionSnapshot*)); // NOLINT | 614 void(const SyncSessionSnapshot*)); // NOLINT |
615 MOCK_METHOD0(OnInitializationComplete, void()); // NOLINT | 615 MOCK_METHOD0(OnInitializationComplete, void()); // NOLINT |
616 MOCK_METHOD1(OnAuthError, void(const GoogleServiceAuthError&)); // NOLINT | 616 MOCK_METHOD1(OnAuthError, void(const GoogleServiceAuthError&)); // NOLINT |
617 MOCK_METHOD1(OnPassphraseRequired, void(bool)); // NOLINT | 617 MOCK_METHOD1(OnPassphraseRequired, void(bool)); // NOLINT |
618 MOCK_METHOD0(OnPassphraseFailed, void()); // NOLINT | 618 MOCK_METHOD0(OnPassphraseFailed, void()); // NOLINT |
619 MOCK_METHOD1(OnPassphraseAccepted, void(const std::string&)); // NOLINT | 619 MOCK_METHOD1(OnPassphraseAccepted, void(const std::string&)); // NOLINT |
620 MOCK_METHOD0(OnPaused, void()); // NOLINT | |
621 MOCK_METHOD0(OnResumed, void()); // NOLINT | |
622 MOCK_METHOD0(OnStopSyncingPermanently, void()); // NOLINT | 620 MOCK_METHOD0(OnStopSyncingPermanently, void()); // NOLINT |
623 MOCK_METHOD1(OnUpdatedToken, void(const std::string&)); // NOLINT | 621 MOCK_METHOD1(OnUpdatedToken, void(const std::string&)); // NOLINT |
624 MOCK_METHOD0(OnClearServerDataFailed, void()); // NOLINT | 622 MOCK_METHOD0(OnClearServerDataFailed, void()); // NOLINT |
625 MOCK_METHOD0(OnClearServerDataSucceeded, void()); // NOLINT | 623 MOCK_METHOD0(OnClearServerDataSucceeded, void()); // NOLINT |
626 MOCK_METHOD1(OnEncryptionComplete, void(const ModelTypeSet&)); // NOLINT | 624 MOCK_METHOD1(OnEncryptionComplete, void(const ModelTypeSet&)); // NOLINT |
627 }; | 625 }; |
628 | 626 |
629 class SyncNotifierMock : public sync_notifier::SyncNotifier { | 627 class SyncNotifierMock : public sync_notifier::SyncNotifier { |
630 public: | 628 public: |
631 MOCK_METHOD1(AddObserver, void(sync_notifier::SyncNotifierObserver*)); | 629 MOCK_METHOD1(AddObserver, void(sync_notifier::SyncNotifierObserver*)); |
(...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1136 true /* is encrypted */)); | 1134 true /* is encrypted */)); |
1137 EXPECT_TRUE(syncable::VerifyDataTypeEncryption(trans.GetWrappedTrans(), | 1135 EXPECT_TRUE(syncable::VerifyDataTypeEncryption(trans.GetWrappedTrans(), |
1138 syncable::THEMES, | 1136 syncable::THEMES, |
1139 false /* not encrypted */)); | 1137 false /* not encrypted */)); |
1140 } | 1138 } |
1141 } | 1139 } |
1142 | 1140 |
1143 } // namespace | 1141 } // namespace |
1144 | 1142 |
1145 } // namespace browser_sync | 1143 } // namespace browser_sync |
OLD | NEW |