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 #ifndef CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_FORM_DATA_H_ | 5 #ifndef CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_FORM_DATA_H_ |
6 #define CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_FORM_DATA_H_ | 6 #define CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_FORM_DATA_H_ |
7 #pragma once | |
8 | 7 |
9 #include <ostream> | 8 #include <ostream> |
10 | 9 |
11 #include "testing/gmock/include/gmock/gmock.h" | 10 #include "testing/gmock/include/gmock/gmock.h" |
12 #include "webkit/forms/password_form.h" | 11 #include "webkit/forms/password_form.h" |
13 | 12 |
14 // Struct used for creation of PasswordForms from static arrays of data. | 13 // Struct used for creation of PasswordForms from static arrays of data. |
15 // Note: This is only meant to be used in unit test. | 14 // Note: This is only meant to be used in unit test. |
16 struct PasswordFormData { | 15 struct PasswordFormData { |
17 const webkit::forms::PasswordForm::Scheme scheme; | 16 const webkit::forms::PasswordForm::Scheme scheme; |
(...skipping 30 matching lines...) Expand all Loading... |
48 std::ostream& operator<<(std::ostream& os, | 47 std::ostream& operator<<(std::ostream& os, |
49 const webkit::forms::PasswordForm& form); | 48 const webkit::forms::PasswordForm& form); |
50 | 49 |
51 // This gmock matcher is used to check that the |arg| contains exactly the same | 50 // This gmock matcher is used to check that the |arg| contains exactly the same |
52 // PasswordForms as |forms|, regardless of order. | 51 // PasswordForms as |forms|, regardless of order. |
53 MATCHER_P(ContainsAllPasswordForms, forms, "") { | 52 MATCHER_P(ContainsAllPasswordForms, forms, "") { |
54 return ContainsSamePasswordFormsPtr(forms, arg); | 53 return ContainsSamePasswordFormsPtr(forms, arg); |
55 } | 54 } |
56 | 55 |
57 #endif // CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_FORM_DATA_H_ | 56 #endif // CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_FORM_DATA_H_ |
OLD | NEW |