aboutsummaryrefslogtreecommitdiffstats
path: root/tests/wpt/web-platform-tests/payment-request/payment-request-not-exposed.https.worker.js
diff options
context:
space:
mode:
Diffstat (limited to 'tests/wpt/web-platform-tests/payment-request/payment-request-not-exposed.https.worker.js')
-rw-r--r--tests/wpt/web-platform-tests/payment-request/payment-request-not-exposed.https.worker.js11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/wpt/web-platform-tests/payment-request/payment-request-not-exposed.https.worker.js b/tests/wpt/web-platform-tests/payment-request/payment-request-not-exposed.https.worker.js
new file mode 100644
index 00000000000..df20f801e9d
--- /dev/null
+++ b/tests/wpt/web-platform-tests/payment-request/payment-request-not-exposed.https.worker.js
@@ -0,0 +1,11 @@
+importScripts("/resources/testharness.js");
+
+test(function() {
+ assert_true(isSecureContext);
+ assert_false('PaymentRequest' in self);
+ assert_false('PaymentRequestUpdateEvent' in self);
+ assert_false('PaymentResponse' in self);
+ assert_false('PaymentAddress' in self);
+}, "PaymentRequest constructor must not be exposed in worker global scope");
+
+done();