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 "app/sql/statement.h" | |
8 #include "base/file_util.h" | 7 #include "base/file_util.h" |
9 #include "base/path_service.h" | 8 #include "base/path_service.h" |
10 #include "base/string_number_conversions.h" | 9 #include "base/string_number_conversions.h" |
11 #include "base/time.h" | 10 #include "base/time.h" |
12 #include "base/utf_string_conversions.h" | 11 #include "base/utf_string_conversions.h" |
13 #include "chrome/common/chrome_paths.h" | |
14 #include "chrome/browser/autofill/autofill_profile.h" | 12 #include "chrome/browser/autofill/autofill_profile.h" |
15 #include "chrome/browser/autofill/autofill_type.h" | 13 #include "chrome/browser/autofill/autofill_type.h" |
16 #include "chrome/browser/autofill/credit_card.h" | 14 #include "chrome/browser/autofill/credit_card.h" |
17 #include "chrome/browser/password_manager/encryptor.h" | 15 #include "chrome/browser/password_manager/encryptor.h" |
18 #include "chrome/browser/webdata/autofill_change.h" | 16 #include "chrome/browser/webdata/autofill_change.h" |
19 #include "chrome/browser/webdata/autofill_entry.h" | 17 #include "chrome/browser/webdata/autofill_entry.h" |
20 #include "chrome/browser/webdata/web_database.h" | 18 #include "chrome/browser/webdata/web_database.h" |
| 19 #include "chrome/common/chrome_paths.h" |
21 #include "chrome/common/guid.h" | 20 #include "chrome/common/guid.h" |
| 21 #include "sql/statement.h" |
22 #include "testing/gtest/include/gtest/gtest.h" | 22 #include "testing/gtest/include/gtest/gtest.h" |
23 #include "webkit/glue/form_field.h" | 23 #include "webkit/glue/form_field.h" |
24 | 24 |
25 using base::Time; | 25 using base::Time; |
26 using base::TimeDelta; | 26 using base::TimeDelta; |
27 using webkit_glue::FormField; | 27 using webkit_glue::FormField; |
28 | 28 |
29 // So we can compare AutofillKeys with EXPECT_EQ(). | 29 // So we can compare AutofillKeys with EXPECT_EQ(). |
30 std::ostream& operator<<(std::ostream& os, const AutofillKey& key) { | 30 std::ostream& operator<<(std::ostream& os, const AutofillKey& key) { |
31 return os << UTF16ToASCII(key.name()) << ", " << UTF16ToASCII(key.value()); | 31 return os << UTF16ToASCII(key.name()) << ", " << UTF16ToASCII(key.value()); |
(...skipping 1568 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1600 | 1600 |
1601 // make sure the lists of entries match | 1601 // make sure the lists of entries match |
1602 ASSERT_EQ(expected_entries.size(), entry_set.size()); | 1602 ASSERT_EQ(expected_entries.size(), entry_set.size()); |
1603 AutofillEntrySetIterator it; | 1603 AutofillEntrySetIterator it; |
1604 for (it = entry_set.begin(); it != entry_set.end(); it++) { | 1604 for (it = entry_set.begin(); it != entry_set.end(); it++) { |
1605 expected_entries.erase(*it); | 1605 expected_entries.erase(*it); |
1606 } | 1606 } |
1607 | 1607 |
1608 EXPECT_EQ(0U, expected_entries.size()); | 1608 EXPECT_EQ(0U, expected_entries.size()); |
1609 } | 1609 } |
OLD | NEW |