OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "components/autofill/core/browser/autofill_test_utils.h" | 5 #include "components/autofill/core/browser/autofill_test_utils.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/guid.h" | 9 #include "base/guid.h" |
10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
(...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
335 table->UnmaskServerCreditCard(card, card.number()); | 335 table->UnmaskServerCreditCard(card, card.number()); |
336 } | 336 } |
337 } | 337 } |
338 | 338 |
339 void FillUploadField(AutofillUploadContents::Field* field, | 339 void FillUploadField(AutofillUploadContents::Field* field, |
340 unsigned signature, | 340 unsigned signature, |
341 const char* name, | 341 const char* name, |
342 const char* control_type, | 342 const char* control_type, |
343 const char* label, | 343 const char* label, |
344 const char* autocomplete, | 344 const char* autocomplete, |
345 unsigned autofill_type) { | 345 unsigned autofill_type, |
| 346 const char* css_classes) { |
346 field->set_signature(signature); | 347 field->set_signature(signature); |
347 if (name) | 348 if (name) |
348 field->set_name(name); | 349 field->set_name(name); |
349 if (control_type) | 350 if (control_type) |
350 field->set_type(control_type); | 351 field->set_type(control_type); |
351 if (label) | 352 if (label) |
352 field->set_label(label); | 353 field->set_label(label); |
353 if (autocomplete) | 354 if (autocomplete) |
354 field->set_autocomplete(autocomplete); | 355 field->set_autocomplete(autocomplete); |
355 field->set_autofill_type(autofill_type); | 356 field->set_autofill_type(autofill_type); |
| 357 if (css_classes) |
| 358 field->set_css_classes(css_classes); |
356 } | 359 } |
357 | 360 |
358 void FillQueryField(AutofillQueryContents::Form::Field* field, | 361 void FillQueryField(AutofillQueryContents::Form::Field* field, |
359 unsigned signature, | 362 unsigned signature, |
360 const char* name, | 363 const char* name, |
361 const char* control_type, | 364 const char* control_type, |
362 const char* label) { | 365 const char* label) { |
363 field->set_signature(signature); | 366 field->set_signature(signature); |
364 if (name) | 367 if (name) |
365 field->set_name(name); | 368 field->set_name(name); |
366 if (control_type) | 369 if (control_type) |
367 field->set_type(control_type); | 370 field->set_type(control_type); |
368 if (label) | 371 if (label) |
369 field->set_label(label); | 372 field->set_label(label); |
370 } | 373 } |
371 | 374 |
372 } // namespace test | 375 } // namespace test |
373 } // namespace autofill | 376 } // namespace autofill |
OLD | NEW |