Commit graph

262 commits

Author SHA1 Message Date
Sam Foster
aa95912b8b Bug 1482689 - Use AddressPicker for the card billing address UI. r=MattN
* New BillingAddressPicker subclass of AddressPicker which just overrides some of the state-related behavior that
* Allow the RichSelect's popupBox (<select>) to be assigned after the constructor
* A couple new mochitests for the new/different behavior
* Update the test to expect 'edit' to be hidden when the empty option is selected

Differential Revision: https://phabricator.services.mozilla.com/D9321

--HG--
extra : moz-landing-system : lando
2018-11-06 00:28:46 +00:00
Matthew Noorenberghe
04e84ad672 Bug 1482689 - Don't import payment-dialog.js from other elements. r=sfoster
Importing payment-dialog.js ends up importing every other element because it imports the elements needed to render the full dialog.
We don't want all of our elements to depend on every other payment one so we shouldn't import payment-dialog.js anywhere in non-test code.

Differential Revision: https://phabricator.services.mozilla.com/D10576

--HG--
extra : moz-landing-system : lando
2018-11-06 00:19:10 +00:00
Brindusan Cristian
94b707cdd4 Backed out changeset ea5d6df24de0 (bug 1482689) as requested by sfoster. 2018-11-06 02:20:51 +02:00
Sam Foster
47668991be Bug 1482689 - Use AddressPicker for the card billing address UI. r=MattN
* New BillingAddressPicker subclass of AddressPicker which just overrides some of the state-related behavior that
* Allow the RichSelect's popupBox (<select>) to be assigned after the constructor
* A couple new mochitests for the new/different behavior
* Update the test to expect 'edit' to be hidden when the empty option is selected

Differential Revision: https://phabricator.services.mozilla.com/D9321

--HG--
extra : moz-landing-system : lando
2018-11-06 00:04:42 +00:00
Cosmin Sabou
d5f49855cd Backed out 2 changesets (bug 1482689) for browser chrome failures on browser_address_edit.js
Backed out changeset 61b49da4b9cb (bug 1482689)
Backed out changeset c810cab5dbdb (bug 1482689)
2018-11-05 18:28:15 +02:00
Sam Foster
2dbcd5bcca Bug 1482689 - Use AddressPicker for the card billing address UI. r=MattN
* New BillingAddressPicker subclass of AddressPicker which just overrides some of the state-related behavior that isn't applicable to billing addresses.
* A couple new mochitests for the new/different behavior

Differential Revision: https://phabricator.services.mozilla.com/D9321

--HG--
extra : moz-landing-system : lando
2018-11-05 15:16:02 +00:00
Matthew Noorenberghe
2e969bf86c Bug 1482689 - Don't import payment-dialog.js from other elements. r=sfoster
Importing payment-dialog.js ends up importing every other element because it imports the elements needed to render the full dialog.
We don't want all of our elements to depend on every other payment one so we shouldn't import payment-dialog.js anywhere in non-test code.

Differential Revision: https://phabricator.services.mozilla.com/D10576

--HG--
extra : moz-landing-system : lando
2018-11-01 22:01:50 +00:00
Jared Wein
ed95c3076b Bug 1497225 - Update the required asterisk display when changing countries. r=sfoster,MattN
Differential Revision: https://phabricator.services.mozilla.com/D10637

--HG--
extra : moz-landing-system : lando
2018-11-02 20:53:12 +00:00
Noemi Erli
bc6ac5be87 Backed out changeset 8cd7b1c3737a (bug 1497225) for failures in browser_editAddressDialog.js 2018-11-02 22:11:24 +02:00
Jared Wein
d29ee44549 Bug 1497225 - Update the required asterisk display when changing countries. r=sfoster,MattN
Differential Revision: https://phabricator.services.mozilla.com/D10637

--HG--
extra : moz-landing-system : lando
2018-11-02 19:03:39 +00:00
Jared Wein
9d2ad063d8 Bug 1483412 - Make the telephone number field required on the payer form if requestPayerPhone is true. r=MattN
Differential Revision: https://phabricator.services.mozilla.com/D10597

--HG--
extra : moz-landing-system : lando
2018-11-01 22:38:03 +00:00
Timothy Guan-tin Chien
f611c1e93c Bug 1429265 - Re-authenticate the user on Windows and macOS before decryption r=MattN
This patch restores the re-auth test pref previously comment out,
and redirect the re-auth to nsIOSReauthenticator on Windows and macOS.

Noted that nsIOSReauthenticator is never called during tests because we can't automate that dialog.

Differential Revision: https://phabricator.services.mozilla.com/D9853

--HG--
extra : moz-landing-system : lando
2018-10-31 23:18:54 +00:00
Eden Chuang
74e578d048 Bug 1497215 - Refactor the IPC structure for PaymentResponse.details r=baku
In original design, payment method response data is passed between processes
    through a simple nsString. It means a special encoder/decoder is needed for
    special response data, ex. BasicCardResponse, to serialize/deserialize
    into/from the nsString. However, when a token spliter, ':', ';' and '@', is
    used in response data, it makes the encoder/decoder can not work normally.
    It is hard to define a suitable token spliter set for encoder/decoder.
    So instead of using an error-prone encoder/decoder, this patch defining a new
    IPC structure for response data.

--HG--
extra : rebase_source : 4972033516bc861ea3f975a27b7688fc6eb89a94
2018-10-29 13:56:32 +01:00
Matthew Noorenberghe
1febad5745 No bug - Update browser/components/payments/ documentation. r=docs
--HG--
extra : rebase_source : a02852de211d57ba7c54b727a8962cae3e17210d
2018-10-25 14:44:26 -07:00
Brendan Dahl
79d0d6f396 Bug 1501478 - Fix payment dialog in browser.xhtml. r=MattN
Differential Revision: https://phabricator.services.mozilla.com/D9602

--HG--
extra : moz-landing-system : lando
2018-10-23 22:43:12 +00:00
Matthew Noorenberghe
319c718b8d Bug 1465673 - Disable browser_card_edit.js in macOS debug builds due to high failure rates. r=me 2018-10-23 15:14:11 -07:00
Margareta Eliza Balazs
1a7c7d8823 Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-10-23 12:31:53 +03:00
Matthew Noorenberghe
9d8e99883d Bug 1486954 - Fix browser/components/payments/test/browser/head.js eslint issue. r=me 2018-10-22 23:13:54 -07:00
Julian Descottes
73e3a16c0d Bug 1499096 - Use ok() with 2 arguments instead of 3 when possible;r=Standard8
Depends on D8740.
This changeset replaces calls to ok with 3 arguments to calls with 2 arguments
in situations where the switch does not have a significant impact on the assert.

Differential Revision: https://phabricator.services.mozilla.com/D8741

--HG--
extra : moz-landing-system : lando
2018-10-23 07:13:35 +00:00
Julian Descottes
2fcd6cb020 Bug 1499096 - Update tests using ok() to is();r=Standard8
This changeset updates all the test that were wrongly using ok() and wanted to
use is() AND for which the assert is still passing without any modification
required.

Differential Revision: https://phabricator.services.mozilla.com/D8739

--HG--
extra : moz-landing-system : lando
2018-10-23 07:12:23 +00:00
Timothy Guan-tin Chien
cb5015982e Bug 1486954 - Part V, Prevent credit card record from being accessed if not initialize r=MattN
This patch changed the initialization of records so that we don't call into credit card
AutofillRecords class if it is pref-off.

Differential Revision: https://phabricator.services.mozilla.com/D9158

--HG--
extra : rebase_source : ee9802af34d8ce63dc3569c10e310762e2271301
extra : histedit_source : 443fb496f872d61b68dcae3bba691c4e1089bf3e
2018-10-18 22:10:25 +00:00
Matthew Noorenberghe
fc94384b79 Bug 1486954 - Part IV, Recover from decryption errors in some places. r=MattN
In case of loss of OS key store key, we should still allow users to go into the manage credit cards dialog and fill the numbers back in.

This is not the migration strategy, see Part III.

Differential Revision: https://phabricator.services.mozilla.com/D5083

--HG--
extra : rebase_source : dc710a2512b0d9b20e0fa74e641867525098eba2
extra : histedit_source : 4983a480565380ce4da6a0f099a5e4ae0e65797d
2018-10-22 22:57:29 -07:00
Matthew Noorenberghe
566350c6ac Bug 1486954 - Part III, Upgrade existing Nightly credit card records to OSKeyStore. r=MattN
For Nightly users who already have credit cards saved in their profile, we will do a one-off upgrade of their encrypted credit card number.
This only applies to users who have NO master password set, to avoid showing them the master password prompt when we migrate.
For those who did, we would quietly delete their credit card record from the store.

Differential Revision: https://phabricator.services.mozilla.com/D8029

--HG--
extra : rebase_source : 2b06e3fc418d5883276850def18966203c16e240
extra : histedit_source : 9fae8d61b747113e8b3f38c2886cf7d1a7c3007f
2018-10-22 22:57:29 -07:00
Timothy Guan-tin Chien
b2023e958b Bug 1486954 - Part I, Encrypt credit card numbers with OS key store. r=MattN
This patch morphs MasterPassword.jsm to OSKeyStore.jsm while keeping the same
API, as an adaptor between the API and the native API exposed as nsIOSKeyStore.idl.

Noted that OS Key Store has the concept of "recovery phrase" that we won't
be adopting here. The recovery phrase, together with our label, allow
the user to re-create the same key in OS key store.

Test case changes are needed because we have started asking for login in
places where we'll only do previously when "master password is enabled".
This also made some "when master password is enabled" tests invalid because
it is always considered enabled.

Some more test changes are needed simply because they previously rely on the
stable order of microtask resolutions (and the stable # of promises for a
specific operation). That has certainly changed with OSKeyStore.

The credit card form autofill is only enabled on Nightly.

Differential Revision: https://phabricator.services.mozilla.com/D4498

--HG--
rename : browser/extensions/formautofill/MasterPassword.jsm => browser/extensions/formautofill/OSKeyStore.jsm
rename : browser/extensions/formautofill/test/browser/browser_creditCard_fill_master_password.js => browser/extensions/formautofill/test/browser/browser_creditCard_fill_cancel_login.js
extra : rebase_source : cabbd8cdec86e5b3965cf1c8b6e635b73b6c2095
extra : histedit_source : 65e71057104465553fefa1d0b293580efed53075
2018-10-17 02:31:04 +00:00
Matthew Noorenberghe
ec9bd73e34 Bug 1435871 - Open prefs from Payment Request in a tab. r=jaws
Differential Revision: https://phabricator.services.mozilla.com/D8497

--HG--
extra : moz-landing-system : lando
2018-10-20 03:40:05 +00:00
Matthew Noorenberghe
b059591dff Bug 1435871 - Implement a basic tab-modal dialog container for Payment Request. r=jaws
Differential Revision: https://phabricator.services.mozilla.com/D7934

--HG--
extra : moz-landing-system : lando
2018-10-20 03:39:32 +00:00
Matthew Noorenberghe
33750c5b1f Bug 1435871 - Back out changeset 3f6664786e85 (Bug 1470584) since it's for a windowed dialog. r=jaws
Differential Revision: https://phabricator.services.mozilla.com/D8272

--HG--
extra : moz-landing-system : lando
2018-10-20 03:38:53 +00:00
Gurzau Raul
8e9ffaaf06 Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-10-20 01:09:52 +03:00
Diego Pino Garcia
ed5d90b2bc Bug 1497514 - Initialize BasicCardPage selectedStateKey to 'selectPaymentCard'. r=MattN
Also require basicCardPage has a selectedStateKey

--HG--
rename : browser/components/payments/test/browser/browser_payments_onboarding_wizard.js => browser/components/payments/test/browser/browser_onboarding_wizard.js
2018-10-18 23:56:00 +03:00
Noemi Erli
e3e15418e9 Backed out changeset 8b3b53341da2 (bug 1497514) for failures in browser/components/payments/test/mochitest/test_basic_card_form.html
--HG--
rename : browser/components/payments/test/browser/browser_onboarding_wizard.js => browser/components/payments/test/browser/browser_payments_onboarding_wizard.js
2018-10-19 03:50:32 +03:00
Diego Pino Garcia
d875812fa7 Bug 1497514 - Initialize BasicCardPage selectedStateKey to 'selectPaymentCard'. r=MattN
Also require basicCardPage has a selectedStateKey

--HG--
rename : browser/components/payments/test/browser/browser_payments_onboarding_wizard.js => browser/components/payments/test/browser/browser_onboarding_wizard.js
extra : rebase_source : f73b3b3f0a5c5ec94ffdbf722f4887097d05d97d
2018-10-18 15:25:49 -07:00
Jared Wein
e85599dc8f Bug 1494551 - Sort the formautofill data by the last used time. r=MattN
Differential Revision: https://phabricator.services.mozilla.com/D9174

--HG--
extra : moz-landing-system : lando
2018-10-19 17:00:31 +00:00
Jared Wein
eb7010591a Bug 1420853 - Ensure only fields valid for the given country are saved. r=MattN
Differential Revision: https://phabricator.services.mozilla.com/D9034

--HG--
extra : moz-landing-system : lando
2018-10-19 16:36:45 +00:00
Brindusan Cristian
28baa2bf3e Backed out changeset 8641e30ebaf4 (bug 1435871) for multiple browser-chrome failures on payments. CLOSED TREE 2018-10-19 14:58:11 +03:00
Brindusan Cristian
1420f3437e Backed out 2 changesets (bug 1435871) for multiple browser-chrome failures on payments. CLOSED TREE
Backed out changeset 0f7592b662e2 (bug 1435871)
Backed out changeset 039f6d65036e (bug 1435871)
2018-10-19 12:36:13 +03:00
Matthew Noorenberghe
783e80be91 Bug 1435871 - Open prefs from Payment Request in a tab. r=jaws
Differential Revision: https://phabricator.services.mozilla.com/D8497

--HG--
extra : moz-landing-system : lando
2018-10-19 05:06:30 +00:00
Matthew Noorenberghe
28552cda7d Bug 1435871 - Implement a basic tab-modal dialog container for Payment Request. r=jaws
Differential Revision: https://phabricator.services.mozilla.com/D7934

--HG--
extra : moz-landing-system : lando
2018-10-19 05:06:22 +00:00
Matthew Noorenberghe
7957bc3803 Bug 1435871 - Back out changeset 3f6664786e85 (Bug 1470584) since it's for a windowed dialog. r=jaws
Differential Revision: https://phabricator.services.mozilla.com/D8272

--HG--
extra : moz-landing-system : lando
2018-10-19 05:06:20 +00:00
Margareta Eliza Balazs
53fc8ddacd Backed out 4 changesets (bug 1486954) for hangs on Linux. a=backout
Backed out changeset c895888bdddc (bug 1486954)
Backed out changeset 27e9286503e8 (bug 1486954)
Backed out changeset 87e64652386d (bug 1486954)
Backed out changeset 96a6e1ceb697 (bug 1486954)

--HG--
rename : browser/extensions/formautofill/OSKeyStore.jsm => browser/extensions/formautofill/MasterPassword.jsm
rename : browser/extensions/formautofill/test/browser/browser_creditCard_fill_cancel_login.js => browser/extensions/formautofill/test/browser/browser_creditCard_fill_master_password.js
2018-10-18 12:40:21 +03:00
Andrei Oprea
3248322b16 Bug 1492671 - Disable screenshot capturing for triggering network requests in payments mochitests r=MattN
Differential Revision: https://phabricator.services.mozilla.com/D8877

--HG--
extra : moz-landing-system : lando
2018-10-17 15:08:50 +00:00
Daniel Varga
e4438031ba Backed out 5 changesets (bug 1496220) for chrome failure at toolkit/content/tests/chrome/test_findbar_events.xul. on a CLOSED TREE
Backed out changeset 2c1353f4a3f5 (bug 1496220)
Backed out changeset bc592bed0522 (bug 1496220)
Backed out changeset 7b5505d44965 (bug 1496220)
Backed out changeset 670b75f8446f (bug 1496220)
Backed out changeset c4a8a6256d7f (bug 1496220)

--HG--
extra : rebase_source : 43edfc28753cca429f7a72994d568091f30e62bc
extra : amend_source : 738723a11e8fb88a71cac79de93b878d82230409
2018-10-17 20:21:16 +03:00
Jim Chen
a4f396d9c8 Bug 1496220 - 5. Pass explicit triggering principal in more places; r=jkt
When defaulting to a null triggering principal, these tests would fail
when loaded remotely. This patch adds explicit system triggering
principal to the loadURI calls.

Differential Revision: https://phabricator.services.mozilla.com/D8461

--HG--
extra : moz-landing-system : lando
2018-10-17 16:12:40 +00:00
Timothy Guan-tin Chien
3aaef61c6c Bug 1486954 - Part IV, Recover from decryption errors in some places r=MattN
In case of loss of OS key store key, we should still allow users to go into the manage credit cards dialog and fill the numbers back in.

This is not the migration strategy, see Part III.

Differential Revision: https://phabricator.services.mozilla.com/D5083

--HG--
extra : moz-landing-system : lando
2018-10-17 02:34:22 +00:00
Timothy Guan-tin Chien
9f7c4d6907 Bug 1486954 - Part III, Upgrade existing Nightly credit card records to OSKeyStore r=MattN
For Nightly users who already have credit cards saved in their profile, we will do a one-off upgrade of their encrypted credit card number.
This only applies to users who have NO master password set, to avoid showing them the master password prompt when we migrate.
For those who did, we would quietly delete their credit card record from the store.

Differential Revision: https://phabricator.services.mozilla.com/D8029

--HG--
extra : moz-landing-system : lando
2018-10-17 02:33:02 +00:00
Timothy Guan-tin Chien
f47a796bf6 Bug 1486954 - Part I, (Nighty-only feature) Encrypt credit card numbers with OS key store r=MattN
This patch morphs MasterPassword.jsm to OSKeyStore.jsm while keeping the same
API, as an adaptor between the API and the native API exposed as nsIOSKeyStore.idl.

Noted that OS Key Store has the concept of "recovery phrase" that we won't
be adopting here. The recovery phrase, together with our label, allow
the user to re-create the same key in OS key store.

Test case changes are needed because we have started asking for login in
places where we'll only do previously when "master password is enabled".
This also made some "when master password is enabled" tests invalid because
it is always considered enabled.

Some more test changes are needed simply because they previously rely on the
stable order of microtask resolutions (and the stable # of promises for a
specific operation). That has certainly changed with OSKeyStore.

The credit card form autofill is only enabled on Nightly.

Differential Revision: https://phabricator.services.mozilla.com/D4498

--HG--
rename : browser/extensions/formautofill/MasterPassword.jsm => browser/extensions/formautofill/OSKeyStore.jsm
rename : browser/extensions/formautofill/test/browser/browser_creditCard_fill_master_password.js => browser/extensions/formautofill/test/browser/browser_creditCard_fill_cancel_login.js
extra : moz-landing-system : lando
2018-10-17 02:31:04 +00:00
Jared Wein
4a3b48e09b Bug 1470199 - Add a tooltip for the CVV input. r=MattN
Differential Revision: https://phabricator.services.mozilla.com/D7473

--HG--
extra : moz-landing-system : lando
2018-10-13 00:39:02 +00:00
Mike Shal
77db47608c Bug 1496698 - Remove res/vendor from jar.mn; r=MattN
Followup to remove the now non-existent directory from the manifest.

MozReview-Commit-ID: 5grb4TgoBsT

Differential Revision: https://phabricator.services.mozilla.com/D8466

--HG--
extra : moz-landing-system : lando
2018-10-11 22:13:34 +00:00
Eden Chuang
05093acbf4 Bug 1441752 - Adding an new attribute regionCode in PaymentAddress. r=baku
--HG--
extra : histedit_source : d71b94a611ff5cd3f5b556de9157ff46a5cfeda6
2018-09-28 12:21:59 +02:00
Matthew Noorenberghe
963ec2ea52 Bug 1496698 - Remove Custom Elements polyfill from Web Payments UI. r=jaws
Differential Revision: https://phabricator.services.mozilla.com/D7863

--HG--
extra : moz-landing-system : lando
2018-10-05 15:37:25 +00:00
Marcos Cáceres
70744c3261 Bug 1495335 - Rename PayerErrorFields to PayerErrors. r=baku 2018-10-01 03:44:00 -04:00