summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/content-security-policy/script-src/worker-set-timeout.sub.html
diff options
context:
space:
mode:
Diffstat (limited to 'testing/web-platform/tests/content-security-policy/script-src/worker-set-timeout.sub.html')
-rw-r--r--testing/web-platform/tests/content-security-policy/script-src/worker-set-timeout.sub.html26
1 files changed, 26 insertions, 0 deletions
diff --git a/testing/web-platform/tests/content-security-policy/script-src/worker-set-timeout.sub.html b/testing/web-platform/tests/content-security-policy/script-src/worker-set-timeout.sub.html
new file mode 100644
index 0000000000..7e73626c6f
--- /dev/null
+++ b/testing/web-platform/tests/content-security-policy/script-src/worker-set-timeout.sub.html
@@ -0,0 +1,26 @@
+<!DOCTYPE html>
+<html>
+
+<head>
+ <meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline' 'self' 'unsafe-eval'; connect-src 'self';">
+ <title>worker-set-timeout</title>
+ <script src="/resources/testharness.js"></script>
+ <script src="/resources/testharnessreport.js"></script>
+ <script src='../support/testharness-helper.js'></script>
+</head>
+
+<body>
+ <script>
+ assert_worker_is_loaded(
+ "./support/worker-with-script-src-none-set-timeout.js",
+ "Dedicated worker delivers its own CSP",
+ "setTimeout blocked");
+
+ assert_shared_worker_is_loaded(
+ "./support/worker-with-script-src-none-set-timeout.js",
+ "Shared worker delivers its own CSP",
+ "setTimeout blocked");
+ </script>
+</body>
+
+</html>