OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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_UI_VIEWS_PAYMENTS_PAYMENT_REQUEST_BROWSERTEST_BASE_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_PAYMENTS_PAYMENT_REQUEST_BROWSERTEST_BASE_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_PAYMENTS_PAYMENT_REQUEST_BROWSERTEST_BASE_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_PAYMENTS_PAYMENT_REQUEST_BROWSERTEST_BASE_H_ |
7 | 7 |
8 #include <list> | 8 #include <list> |
9 #include <memory> | 9 #include <memory> |
10 #include <string> | 10 #include <string> |
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
170 // Whether the editor textfield/combobox for the given |type| is currently in | 170 // Whether the editor textfield/combobox for the given |type| is currently in |
171 // an invalid state. | 171 // an invalid state. |
172 bool IsEditorTextfieldInvalid(autofill::ServerFieldType type); | 172 bool IsEditorTextfieldInvalid(autofill::ServerFieldType type); |
173 bool IsEditorComboboxInvalid(autofill::ServerFieldType type); | 173 bool IsEditorComboboxInvalid(autofill::ServerFieldType type); |
174 | 174 |
175 bool IsPayButtonEnabled(); | 175 bool IsPayButtonEnabled(); |
176 | 176 |
177 // Sets proper animation delegates and waits for animation to finish. | 177 // Sets proper animation delegates and waits for animation to finish. |
178 void WaitForAnimation(); | 178 void WaitForAnimation(); |
179 | 179 |
180 // Returns the text of the StyledLabel with the specific |view_id| that is a | 180 // Returns the text of the Label or StyledLabel with the specific |view_id| |
181 // child of the Payment Request dialog view. | 181 // that is a child of the Payment Request dialog view. |
| 182 const base::string16& GetLabelText(DialogViewID view_id); |
182 const base::string16& GetStyledLabelText(DialogViewID view_id); | 183 const base::string16& GetStyledLabelText(DialogViewID view_id); |
183 // Returns the error label text associated with a given field |type|. | 184 // Returns the error label text associated with a given field |type|. |
184 const base::string16& GetErrorLabelForType(autofill::ServerFieldType type); | 185 const base::string16& GetErrorLabelForType(autofill::ServerFieldType type); |
185 | 186 |
186 net::EmbeddedTestServer* https_server() { return https_server_.get(); } | 187 net::EmbeddedTestServer* https_server() { return https_server_.get(); } |
187 | 188 |
188 PaymentRequestDialogView* dialog_view() { return delegate_->dialog_view(); } | 189 PaymentRequestDialogView* dialog_view() { return delegate_->dialog_view(); } |
189 | 190 |
190 void SetRegionDataLoader(autofill::RegionDataLoader* region_data_loader) { | 191 void SetRegionDataLoader(autofill::RegionDataLoader* region_data_loader) { |
191 delegate_->SetRegionDataLoader(region_data_loader); | 192 delegate_->SetRegionDataLoader(region_data_loader); |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
259 TestChromePaymentRequestDelegate* delegate_; | 260 TestChromePaymentRequestDelegate* delegate_; |
260 bool is_incognito_; | 261 bool is_incognito_; |
261 bool is_valid_ssl_; | 262 bool is_valid_ssl_; |
262 | 263 |
263 DISALLOW_COPY_AND_ASSIGN(PaymentRequestBrowserTestBase); | 264 DISALLOW_COPY_AND_ASSIGN(PaymentRequestBrowserTestBase); |
264 }; | 265 }; |
265 | 266 |
266 } // namespace payments | 267 } // namespace payments |
267 | 268 |
268 #endif // CHROME_BROWSER_UI_VIEWS_PAYMENTS_PAYMENT_REQUEST_BROWSERTEST_BASE_H_ | 269 #endif // CHROME_BROWSER_UI_VIEWS_PAYMENTS_PAYMENT_REQUEST_BROWSERTEST_BASE_H_ |
OLD | NEW |