Revision 654dc43664f0ff6b84609d334cb05147c0594fbd authored by Robert Ma on 16 March 2018, 00:32:55 UTC, committed by Robert Ma on 16 March 2018, 17:02:47 UTC
ChromeDriver doesn't honor PATH and uses /opt/google/chrome/chrome by
default (which is usually the stable channel), so we need to explicitly
pass the desired binary path to wpt run (which in turn passes to
chromedriver via capabilities) in Travis CI (both stability check and
infrastructure test).
1 parent 89ba944
Raw File
payment-request-shippingAddress-attribute.https.html
<!DOCTYPE html>
<!-- Copyright © 2017 Chromium authors and World Wide Web Consortium, (Massachusetts Institute of Technology, ERCIM, Keio University, Beihang). -->
<meta charset="utf-8">
<title>Test for PaymentRequest shippingAddress attribute</title>
<link rel="help" href="https://w3c.github.io/payment-request/#shippingaddress-attribute">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>
const validMethod = Object.freeze({ supportedMethods: "foo" });
const validMethods = Object.freeze([validMethod]);
const validAmount = Object.freeze({ currency: "USD", value: "5.00" });
const validTotal = Object.freeze({
  label: "label",
  amount: validAmount,
});
const validDetails = Object.freeze({ total: validTotal });

test(() => {
  const request = new PaymentRequest(validMethods, validDetails);
  assert_idl_attribute(request, "shippingAddress");
}, "Must have a .shippingAddress IDL attribute.");

test(() => {
  const request = new PaymentRequest(validMethods, validDetails);
  assert_equals(request.shippingAddress, null, "expected null");
}, ".shippingAddress attribute must default to null.");

</script>
back to top