Index: third_party/WebKit/LayoutTests/http/tests/notifications/serviceworker-notificationclose-event-data-reflection.html |
diff --git a/third_party/WebKit/LayoutTests/http/tests/notifications/serviceworker-notificationclose-event-data-reflection.html b/third_party/WebKit/LayoutTests/http/tests/notifications/serviceworker-notificationclose-event-data-reflection.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..9203c272eb14af24812a9552f27b6a715b819071 |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/http/tests/notifications/serviceworker-notificationclose-event-data-reflection.html |
@@ -0,0 +1,28 @@ |
+<!doctype html> |
+<html> |
+ <head> |
+ <title>Notifications: Action reflection in the "notificationclose" event.</title> |
+ <script src="../resources/permissions-helper.js"></script> |
+ <script src="../resources/testharness.js"></script> |
+ <script src="../resources/testharnessreport.js"></script> |
+ <script src="../serviceworker/resources/test-helpers.js"></script> |
+ <script src="resources/notification-data-reflection-test.js"></script> |
+ <script src="resources/test-helpers.js"></script> |
+ </head> |
+ <body> |
+ <script> |
+ // Tests that the notification available in the "notificationclose" event in the |
+ // Service Worker accurately reflects the data attributes of several type |
+ // with which the notification was created (for this test --) in the document. |
+ |
+ async_test(function(test) { |
+ runNotificationDataReflectionTest(test, { |
+ run: function (scope) { |
+ testRunner.simulateWebNotificationClose(scope, true /* by_user */); |
+ }, |
+ name: 'close' |
+ }); |
+ }, 'NotificationEvent data property should be reflected when the notification is closed by the user.'); |
+ </script> |
+ </body> |
+</html> |