Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(108)

Unified Diff: LayoutTests/http/tests/notifications/resources/serviceworker-notification-event.js

Issue 780963004: Use event init dictionaries in modules/{notifications,push_messaging,serviceworkers} (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | LayoutTests/http/tests/push_messaging/resources/pushevent-extendable-event.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/http/tests/notifications/resources/serviceworker-notification-event.js
diff --git a/LayoutTests/http/tests/notifications/resources/serviceworker-notification-event.js b/LayoutTests/http/tests/notifications/resources/serviceworker-notification-event.js
index 1788eed555717e267dc5e5e0531b993d2f07b48c..fd545ea85582bcb349f95824cea07fa94c0cd0a5 100644
--- a/LayoutTests/http/tests/notifications/resources/serviceworker-notification-event.js
+++ b/LayoutTests/http/tests/notifications/resources/serviceworker-notification-event.js
@@ -7,8 +7,21 @@ test(function() {
var event = new NotificationEvent('NotificationEvent');
assert_equals(event.type, 'NotificationEvent');
assert_own_property(event, 'notification');
+ assert_equals(event.cancelable, false);
+ assert_equals(event.bubbles, false);
+ assert_equals(event.notification, null);
assert_inherits(event, 'waitUntil');
+ var notification = new Notification('foo');
+ var eventWithInit = new NotificationEvent('NotificationEvent',
+ { cancelable: true,
+ bubbles: true,
+ notification: notification,
+ });
+ assert_equals(eventWithInit.cancelable, true);
+ assert_equals(eventWithInit.bubbles, true);
+ assert_equals(eventWithInit.notification, notification);
+
}, 'NotificationEvent is exposed, and has the expected interface.');
test(function() {
« no previous file with comments | « no previous file | LayoutTests/http/tests/push_messaging/resources/pushevent-extendable-event.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698