diff options
Diffstat (limited to 'browser/extensions/formautofill/test/mochitest/creditCard/test_creditcard_autocomplete_off.html')
-rw-r--r-- | browser/extensions/formautofill/test/mochitest/creditCard/test_creditcard_autocomplete_off.html | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/browser/extensions/formautofill/test/mochitest/creditCard/test_creditcard_autocomplete_off.html b/browser/extensions/formautofill/test/mochitest/creditCard/test_creditcard_autocomplete_off.html index 04ff6ff85c..c42a1ad2d0 100644 --- a/browser/extensions/formautofill/test/mochitest/creditCard/test_creditcard_autocomplete_off.html +++ b/browser/extensions/formautofill/test/mochitest/creditCard/test_creditcard_autocomplete_off.html @@ -49,6 +49,11 @@ async function setupFormHistory() { ]); } +function replaceStars(str) +{ + return str.replaceAll("*", "•") +} + initPopupListener(); // Show Form History popup for non-autocomplete="off" field only @@ -73,7 +78,7 @@ add_task(async function check_menu_when_both_with_autocomplete_off() { synthesizeKey("KEY_ArrowDown"); await expectPopup(); checkMenuEntries(MOCK_STORAGE.map(patchRecordCCNumber).map(({ cc, expected }) => JSON.stringify({ - primary: cc.ccNumberFmt, + primary: replaceStars(cc.ccNumberFmt), secondary: cc["cc-name"], ariaLabel: `${getCCTypeName(cc)} ${cc.ccNumberFmt.replaceAll("*", "")} ${cc["cc-name"]}`, image: expected.image, @@ -84,7 +89,7 @@ add_task(async function check_menu_when_both_with_autocomplete_off() { await expectPopup(); checkMenuEntries(MOCK_STORAGE.map(patchRecordCCNumber).map(({ cc, expected }) => JSON.stringify({ primary: cc["cc-name"], - secondary: cc.ccNumberFmt, + secondary: replaceStars(cc.ccNumberFmt), ariaLabel: `${getCCTypeName(cc)} ${cc["cc-name"]} ${cc.ccNumberFmt}`, image: expected.image, }))); |