Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: make PMIs conform to spec #14163

Merged
merged 2 commits into from
Feb 14, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions payment-method-basic-card/empty-data-manual.https.html
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@
};

async function getCardResponse(data) {
const method = Object.assign({ data }, methodCard);
const response = await new PaymentRequest([method], defaultDetails).show();
const payMethod = Object.assign({ data }, method);
const response = await new PaymentRequest([payMethod], details).show();
await response.complete("success");
return response.details;
}
Expand All @@ -54,7 +54,7 @@
promise_test(async () => {
const card = await getCardResponse(data);
for (const [member, expectedValue] of Object.entries(expectedCard)) {
const msg = `Expected card.${member} to equal ${expectedValue}.`;
const msg = `Expected "card.${member}" to equal "${expectedValue}".`;
assert_equals(card[member], expectedValue, msg);
}
const { billingAddress } = card;
Expand Down Expand Up @@ -120,6 +120,11 @@ <h2>
Returns a card on any network, because zero length supportedNetworks.
</button>
</li>
<li>
<button onclick="done();">
Done!
</button>
</li>
</ol>

<small>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
function* pmiGenerator(howMany = 256) {
for (i = 0; i < howMany; i++) {
yield {
supportedMethods: `this-is-not-supported-${i}`,
supportedMethods: `this-is-not-supported`,
data: { key: "value" },
};
}
Expand Down