summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/service-workers/service-worker/resources/install-event-type-worker.js
diff options
context:
space:
mode:
Diffstat (limited to 'testing/web-platform/tests/service-workers/service-worker/resources/install-event-type-worker.js')
-rw-r--r--testing/web-platform/tests/service-workers/service-worker/resources/install-event-type-worker.js9
1 files changed, 9 insertions, 0 deletions
diff --git a/testing/web-platform/tests/service-workers/service-worker/resources/install-event-type-worker.js b/testing/web-platform/tests/service-workers/service-worker/resources/install-event-type-worker.js
new file mode 100644
index 0000000000..1c94ae21ea
--- /dev/null
+++ b/testing/web-platform/tests/service-workers/service-worker/resources/install-event-type-worker.js
@@ -0,0 +1,9 @@
+importScripts('worker-testharness.js');
+
+self.oninstall = function(event) {
+ assert_true(event instanceof ExtendableEvent, 'instance of ExtendableEvent');
+ assert_true(event instanceof InstallEvent, 'instance of InstallEvent');
+ assert_equals(event.type, 'install', '`type` property value');
+ assert_false(event.cancelable, '`cancelable` property value');
+ assert_false(event.bubbles, '`bubbles` property value');
+};