| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <script src="../resources/testharness.js"></script> | 2 <script src="../resources/testharness.js"></script> |
| 3 <script src="../resources/testharnessreport.js"></script> | 3 <script src="../resources/testharnessreport.js"></script> |
| 4 <script src="../resources/mojo-helpers.js"></script> | 4 <script src="../resources/mojo-helpers.js"></script> |
| 5 <script src="resources/payment-request-mock.js"></script> | 5 <script src="resources/payment-request-mock.js"></script> |
| 6 <script> | 6 <script> |
| 7 var details = { | 7 var details = { |
| 8 items: [ | 8 items: [ |
| 9 { | 9 { |
| 10 id: 'bar', | 10 id: 'bar', |
| 11 label: 'Sub-total', | 11 label: 'Sub-total', |
| 12 amount: { currencyCode: 'USD', value : '55.00' }, // US$55.00 | 12 amount: { currency: 'USD', value : '55.00' }, // US$55.00 |
| 13 }, | 13 }, |
| 14 { | 14 { |
| 15 id: 'foo', | 15 id: 'foo', |
| 16 label: 'Sales Tax', | 16 label: 'Sales Tax', |
| 17 amount: { currencyCode: 'USD', value : '5.00' }, // US$5.00 | 17 amount: { currency: 'USD', value : '5.00' }, // US$5.00 |
| 18 } | 18 } |
| 19 ] | 19 ] |
| 20 }; | 20 }; |
| 21 | 21 |
| 22 var response_data = { | 22 var response_data = { |
| 23 method_name: 'visa', | 23 method_name: 'visa', |
| 24 stringified_details: '{}' | 24 stringified_details: '{}' |
| 25 }; | 25 }; |
| 26 | 26 |
| 27 promise_test(t => { | 27 promise_test(t => { |
| (...skipping 12 matching lines...) Expand all Loading... |
| 40 // Return before calling gc() to make sure reference to response | 40 // Return before calling gc() to make sure reference to response |
| 41 // is gone. | 41 // is gone. |
| 42 }) | 42 }) |
| 43 .then(() => { | 43 .then(() => { |
| 44 gc(); | 44 gc(); |
| 45 mock.onComplete(); | 45 mock.onComplete(); |
| 46 return completeResult; | 46 return completeResult; |
| 47 }); | 47 }); |
| 48 }, 'Promises resolve even without references to request or response.'); | 48 }, 'Promises resolve even without references to request or response.'); |
| 49 </script> | 49 </script> |
| OLD | NEW |