Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4982)

Unified Diff: chrome/test/data/webui/settings/settings_autofill_section_browsertest.js

Issue 2681143004: MD Settings: in autofill section, change google-payment related entries to outlinks instead. (Closed)
Patch Set: fix unit tests Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/resources/settings/passwords_and_forms_page/passwords_shared_css.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/data/webui/settings/settings_autofill_section_browsertest.js
diff --git a/chrome/test/data/webui/settings/settings_autofill_section_browsertest.js b/chrome/test/data/webui/settings/settings_autofill_section_browsertest.js
index 7228b71e540ca93b5b58f24a995c0fbd00c57d63..4af3b281b2d2e29f41b9d23298e93ba72ece6e58 100644
--- a/chrome/test/data/webui/settings/settings_autofill_section_browsertest.js
+++ b/chrome/test/data/webui/settings/settings_autofill_section_browsertest.js
@@ -217,6 +217,32 @@ TEST_F('SettingsAutofillSectionBrowserTest', 'CreditCardTests', function() {
row.querySelector('#creditCardExpiration').textContent);
});
+ test('verifyCreditCardRowButtonIsDropdownWhenLocal', function() {
+ var creditCard = FakeDataMaker.creditCardEntry();
+ creditCard.metadata.isLocal = true;
+ var section = self.createAutofillSection_([], [creditCard]);
+ var creditCardList = section.$.creditCardList;
+ var row = creditCardList.children[0];
+ assertTrue(!!row);
+ var menuButton = row.querySelector('#creditCardMenu');
+ assertTrue(!!menuButton);
+ var outlinkButton = row.querySelector('[is="paper-icon-button-light"');
+ assertFalse(!!outlinkButton);
+ });
+
+ test('verifyCreditCardRowButtonIsOutlinkWhenRemote', function() {
+ var creditCard = FakeDataMaker.creditCardEntry();
+ creditCard.metadata.isLocal = false;
+ var section = self.createAutofillSection_([], [creditCard]);
+ var creditCardList = section.$.creditCardList;
+ var row = creditCardList.children[0];
+ assertTrue(!!row);
+ var menuButton = row.querySelector('#creditCardMenu');
+ assertFalse(!!menuButton);
+ var outlinkButton = row.querySelector('[is="paper-icon-button-light"');
+ assertTrue(!!outlinkButton);
+ });
+
test('verifyAddVsEditCreditCardTitle', function() {
var newCreditCard = FakeDataMaker.emptyCreditCardEntry();
var newCreditCardDialog = self.createCreditCardDialog_(newCreditCard);
@@ -430,6 +456,32 @@ TEST_F('SettingsAutofillSectionBrowserTest', 'AddressTests', function() {
assertEquals(addressSummary, actualSummary);
});
+ test('verifyAddressRowButtonIsDropdownWhenLocal', function() {
+ var address = FakeDataMaker.addressEntry();
+ address.metadata.isLocal = true;
+ var section = self.createAutofillSection_([address], []);
+ var addressList = section.$.addressList;
+ var row = addressList.children[0];
+ assertTrue(!!row);
+ var menuButton = row.querySelector('#addressMenu')
+ assertTrue(!!menuButton);
+ var outlinkButton = row.querySelector('[is="paper-icon-button-light"]');
+ assertFalse(!!outlinkButton);
+ });
+
+ test('verifyAddressRowButtonIsOutlinkWhenRemote', function() {
+ var address = FakeDataMaker.addressEntry();
+ address.metadata.isLocal = false;
+ var section = self.createAutofillSection_([address], []);
+ var addressList = section.$.addressList;
+ var row = addressList.children[0];
+ assertTrue(!!row);
+ var menuButton = row.querySelector('#addressMenu')
+ assertFalse(!!menuButton);
+ var outlinkButton = row.querySelector('[is="paper-icon-button-light"]');
+ assertTrue(!!outlinkButton);
+ });
+
test('verifyAddAddressDialog', function() {
return self.createAddressDialog_(
FakeDataMaker.emptyAddressEntry()).then(function(dialog) {
« no previous file with comments | « chrome/browser/resources/settings/passwords_and_forms_page/passwords_shared_css.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698