| 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 #include <vector> | 5 #include <vector> |
| 6 | 6 |
| 7 #include "base/memory/ref_counted.h" | 7 #include "base/memory/ref_counted.h" |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "base/string16.h" | 9 #include "base/string16.h" |
| 10 #include "base/time.h" | 10 #include "base/time.h" |
| (...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 110 MOCK_METHOD1(SaveImportedCreditCard, | 110 MOCK_METHOD1(SaveImportedCreditCard, |
| 111 void(const CreditCard& imported_credit_card)); | 111 void(const CreditCard& imported_credit_card)); |
| 112 | 112 |
| 113 private: | 113 private: |
| 114 void CreateTestAutofillProfiles(ScopedVector<AutofillProfile>* profiles) { | 114 void CreateTestAutofillProfiles(ScopedVector<AutofillProfile>* profiles) { |
| 115 AutofillProfile* profile = new AutofillProfile; | 115 AutofillProfile* profile = new AutofillProfile; |
| 116 autofill_test::SetProfileInfo(profile, "Elvis", "Aaron", | 116 autofill_test::SetProfileInfo(profile, "Elvis", "Aaron", |
| 117 "Presley", "theking@gmail.com", "RCA", | 117 "Presley", "theking@gmail.com", "RCA", |
| 118 "3734 Elvis Presley Blvd.", "Apt. 10", | 118 "3734 Elvis Presley Blvd.", "Apt. 10", |
| 119 "Memphis", "Tennessee", "38116", "USA", | 119 "Memphis", "Tennessee", "38116", "USA", |
| 120 "12345678901", ""); | 120 "12345678901"); |
| 121 profile->set_guid("00000000-0000-0000-0000-000000000001"); | 121 profile->set_guid("00000000-0000-0000-0000-000000000001"); |
| 122 profiles->push_back(profile); | 122 profiles->push_back(profile); |
| 123 profile = new AutofillProfile; | 123 profile = new AutofillProfile; |
| 124 autofill_test::SetProfileInfo(profile, "Charles", "Hardin", | 124 autofill_test::SetProfileInfo(profile, "Charles", "Hardin", |
| 125 "Holley", "buddy@gmail.com", "Decca", | 125 "Holley", "buddy@gmail.com", "Decca", |
| 126 "123 Apple St.", "unit 6", "Lubbock", | 126 "123 Apple St.", "unit 6", "Lubbock", |
| 127 "Texas", "79401", "USA", "2345678901", | 127 "Texas", "79401", "USA", "2345678901"); |
| 128 ""); | |
| 129 profile->set_guid("00000000-0000-0000-0000-000000000002"); | 128 profile->set_guid("00000000-0000-0000-0000-000000000002"); |
| 130 profiles->push_back(profile); | 129 profiles->push_back(profile); |
| 131 } | 130 } |
| 132 | 131 |
| 133 bool autofill_enabled_; | 132 bool autofill_enabled_; |
| 134 | 133 |
| 135 DISALLOW_COPY_AND_ASSIGN(TestPersonalDataManager); | 134 DISALLOW_COPY_AND_ASSIGN(TestPersonalDataManager); |
| 136 }; | 135 }; |
| 137 | 136 |
| 138 class TestFormStructure : public FormStructure { | 137 class TestFormStructure : public FormStructure { |
| (...skipping 1261 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1400 autofill_manager_->OnTextFieldDidChange(form, form.fields.front(), | 1399 autofill_manager_->OnTextFieldDidChange(form, form.fields.front(), |
| 1401 TimeTicks::FromInternalValue(3)); | 1400 TimeTicks::FromInternalValue(3)); |
| 1402 autofill_manager_->OnFormSubmitted(form, TimeTicks::FromInternalValue(17)); | 1401 autofill_manager_->OnFormSubmitted(form, TimeTicks::FromInternalValue(17)); |
| 1403 autofill_manager_->Reset(); | 1402 autofill_manager_->Reset(); |
| 1404 Mock::VerifyAndClearExpectations(autofill_manager_->metric_logger()); | 1403 Mock::VerifyAndClearExpectations(autofill_manager_->metric_logger()); |
| 1405 } | 1404 } |
| 1406 | 1405 |
| 1407 // Restore the global Gmock verbosity level to its default value. | 1406 // Restore the global Gmock verbosity level to its default value. |
| 1408 ::testing::FLAGS_gmock_verbose = "warning"; | 1407 ::testing::FLAGS_gmock_verbose = "warning"; |
| 1409 } | 1408 } |
| OLD | NEW |