| 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 <set> | 5 #include <set> |
| 6 #include <string> | 6 #include <string> |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "testing/gtest/include/gtest/gtest.h" | 9 #include "testing/gtest/include/gtest/gtest.h" |
| 10 | 10 |
| (...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 319 EXPECT_CALL(*factory, CreateSharedChangeProcessor()). | 319 EXPECT_CALL(*factory, CreateSharedChangeProcessor()). |
| 320 WillOnce(MakeSharedChangeProcessor()); | 320 WillOnce(MakeSharedChangeProcessor()); |
| 321 EXPECT_CALL(*factory, | 321 EXPECT_CALL(*factory, |
| 322 GetSyncableServiceForType(syncable::AUTOFILL_PROFILE)). | 322 GetSyncableServiceForType(syncable::AUTOFILL_PROFILE)). |
| 323 WillOnce(MakeAutofillProfileSyncComponents(wds)); | 323 WillOnce(MakeAutofillProfileSyncComponents(wds)); |
| 324 } | 324 } |
| 325 }; | 325 }; |
| 326 | 326 |
| 327 class PersonalDataManagerMock: public PersonalDataManager { | 327 class PersonalDataManagerMock: public PersonalDataManager { |
| 328 public: | 328 public: |
| 329 static ProfileKeyedBase* Build(Profile* profile) { | 329 static ProfileKeyedService* Build(Profile* profile) { |
| 330 return new PersonalDataManagerMock; | 330 return new PersonalDataManagerMock; |
| 331 } | 331 } |
| 332 | 332 |
| 333 MOCK_CONST_METHOD0(IsDataLoaded, bool()); | 333 MOCK_CONST_METHOD0(IsDataLoaded, bool()); |
| 334 MOCK_METHOD0(LoadProfiles, void()); | 334 MOCK_METHOD0(LoadProfiles, void()); |
| 335 MOCK_METHOD0(LoadCreditCards, void()); | 335 MOCK_METHOD0(LoadCreditCards, void()); |
| 336 MOCK_METHOD0(Refresh, void()); | 336 MOCK_METHOD0(Refresh, void()); |
| 337 }; | 337 }; |
| 338 template <class T> class AddAutofillHelper; | 338 template <class T> class AddAutofillHelper; |
| 339 | 339 |
| (...skipping 885 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1225 std::vector<AutofillEntry> sync_entries; | 1225 std::vector<AutofillEntry> sync_entries; |
| 1226 std::vector<AutofillProfile> sync_profiles; | 1226 std::vector<AutofillProfile> sync_profiles; |
| 1227 ASSERT_TRUE(GetAutofillEntriesFromSyncDB(&sync_entries, &sync_profiles)); | 1227 ASSERT_TRUE(GetAutofillEntriesFromSyncDB(&sync_entries, &sync_profiles)); |
| 1228 EXPECT_EQ(3U, sync_entries.size()); | 1228 EXPECT_EQ(3U, sync_entries.size()); |
| 1229 EXPECT_EQ(0U, sync_profiles.size()); | 1229 EXPECT_EQ(0U, sync_profiles.size()); |
| 1230 for (size_t i = 0; i < sync_entries.size(); i++) { | 1230 for (size_t i = 0; i < sync_entries.size(); i++) { |
| 1231 DVLOG(1) << "Entry " << i << ": " << sync_entries[i].key().name() | 1231 DVLOG(1) << "Entry " << i << ": " << sync_entries[i].key().name() |
| 1232 << ", " << sync_entries[i].key().value(); | 1232 << ", " << sync_entries[i].key().value(); |
| 1233 } | 1233 } |
| 1234 } | 1234 } |
| OLD | NEW |