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

Side by Side Diff: third_party/WebKit/LayoutTests/external/wpt/payment-request/payment-request-id.https.html

Issue 2770193003: Implement request id in PaymentDetailsInit (Closed)
Patch Set: Rebase once more since mojom file moved Created 3 years, 7 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 unified diff | Download patch
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <!-- Copyright © 2017 Chromium authors and World Wide Web Consortium, (Massachus etts Institute of Technology, ERCIM, Keio University, Beihang). -->
3 <meta charset="utf-8">
4 <title>Test for PaymentRequest identifier usage</title>
5 <script src="/resources/testharness.js"></script>
6 <script src="/resources/testharnessreport.js"></script>
7 <iframe id="iframe" allowpaymentrequest></iframe>
8 <script>
9 async_test((t) => {
10 onload = t.step_func_done(() => {
11 var request = new window[0].PaymentRequest([{supportedMethods: ['foo']}], {i d: 'my_payment_id', total: {label: 'label', amount: {currency: 'USD', value: '5. 00'}}});
12 assert_equals(request.id, 'my_payment_id', 'Payment identifier is not reflec ted correctly in PaymentRequest.id');
13
14 request = new window[0].PaymentRequest([{supportedMethods: ['foo']}], {total : {label: 'label', amount: {currency: 'USD', value: '5.00'}}});
15 assert_equals(request.id.length, 36, 'Generated payment identifier is not of correct length.');
16 });
17 });
18 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698