| 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/password_manager/password_store_mac.h" | 5 #include "chrome/browser/password_manager/password_store_mac.h" |
| 6 | 6 |
| 7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
| 8 #include "base/files/scoped_temp_dir.h" | 8 #include "base/files/scoped_temp_dir.h" |
| 9 #include "base/scoped_observer.h" | 9 #include "base/scoped_observer.h" |
| 10 #include "base/stl_util.h" | 10 #include "base/stl_util.h" |
| (...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 156 } | 156 } |
| 157 EXPECT_EQ(expectation->preferred, form->preferred); | 157 EXPECT_EQ(expectation->preferred, form->preferred); |
| 158 EXPECT_EQ(expectation->ssl_valid, form->ssl_valid); | 158 EXPECT_EQ(expectation->ssl_valid, form->ssl_valid); |
| 159 EXPECT_DOUBLE_EQ(expectation->creation_time, | 159 EXPECT_DOUBLE_EQ(expectation->creation_time, |
| 160 form->date_created.ToDoubleT()); | 160 form->date_created.ToDoubleT()); |
| 161 base::Time created = base::Time::FromDoubleT(expectation->creation_time); | 161 base::Time created = base::Time::FromDoubleT(expectation->creation_time); |
| 162 EXPECT_EQ( | 162 EXPECT_EQ( |
| 163 created + base::TimeDelta::FromDays( | 163 created + base::TimeDelta::FromDays( |
| 164 password_manager::kTestingDaysAfterPasswordsAreSynced), | 164 password_manager::kTestingDaysAfterPasswordsAreSynced), |
| 165 form->date_synced); | 165 form->date_synced); |
| 166 EXPECT_EQ(GURL(password_manager::kTestingAvatarUrlSpec), form->avatar_url); | 166 EXPECT_EQ(GURL(password_manager::kTestingIconUrlSpec), form->icon_url); |
| 167 } | 167 } |
| 168 } | 168 } |
| 169 | 169 |
| 170 PasswordStoreChangeList AddChangeForForm(const PasswordForm& form) { | 170 PasswordStoreChangeList AddChangeForForm(const PasswordForm& form) { |
| 171 return PasswordStoreChangeList( | 171 return PasswordStoreChangeList( |
| 172 1, PasswordStoreChange(PasswordStoreChange::ADD, form)); | 172 1, PasswordStoreChange(PasswordStoreChange::ADD, form)); |
| 173 } | 173 } |
| 174 | 174 |
| 175 } // namespace | 175 } // namespace |
| 176 | 176 |
| (...skipping 1680 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1857 histogram_tester_->ExpectUniqueSample( | 1857 histogram_tester_->ExpectUniqueSample( |
| 1858 "PasswordManager.KeychainMigration.NumPasswordsOnFailure", 1, 1); | 1858 "PasswordManager.KeychainMigration.NumPasswordsOnFailure", 1, 1); |
| 1859 histogram_tester_->ExpectUniqueSample( | 1859 histogram_tester_->ExpectUniqueSample( |
| 1860 "PasswordManager.KeychainMigration.NumFailedPasswords", 1, 1); | 1860 "PasswordManager.KeychainMigration.NumFailedPasswords", 1, 1); |
| 1861 histogram_tester_->ExpectUniqueSample( | 1861 histogram_tester_->ExpectUniqueSample( |
| 1862 "PasswordManager.KeychainMigration.NumChromeOwnedInaccessiblePasswords", | 1862 "PasswordManager.KeychainMigration.NumChromeOwnedInaccessiblePasswords", |
| 1863 2, 1); | 1863 2, 1); |
| 1864 // Don't test the encryption key access. | 1864 // Don't test the encryption key access. |
| 1865 histogram_tester_.reset(); | 1865 histogram_tester_.reset(); |
| 1866 } | 1866 } |
| OLD | NEW |