| Index: third_party/WebKit/LayoutTests/http/tests/notifications/serviceworkerregistration-get-replacement.html
|
| diff --git a/third_party/WebKit/LayoutTests/http/tests/notifications/serviceworkerregistration-get-filter.html b/third_party/WebKit/LayoutTests/http/tests/notifications/serviceworkerregistration-get-replacement.html
|
| similarity index 82%
|
| copy from third_party/WebKit/LayoutTests/http/tests/notifications/serviceworkerregistration-get-filter.html
|
| copy to third_party/WebKit/LayoutTests/http/tests/notifications/serviceworkerregistration-get-replacement.html
|
| index 2f17912883b4d11f7698ceccf3d290f412d6fdc9..94ca913b252a134ef63dc00f51ca99654e86bc77 100644
|
| --- a/third_party/WebKit/LayoutTests/http/tests/notifications/serviceworkerregistration-get-filter.html
|
| +++ b/third_party/WebKit/LayoutTests/http/tests/notifications/serviceworkerregistration-get-replacement.html
|
| @@ -1,7 +1,7 @@
|
| <!doctype html>
|
| <html>
|
| <head>
|
| - <title>Notifications: ServiceWorkerRegistration.getNotifications() with a filter.</title>
|
| + <title>Notifications: ServiceWorkerRegistration.getNotifications() with a notification replacement.</title>
|
| <script src="../resources/testharness.js"></script>
|
| <script src="../resources/testharnessreport.js"></script>
|
| <script src="../serviceworker/resources/test-helpers.js"></script>
|
| @@ -10,8 +10,8 @@
|
| <body>
|
| <script>
|
| // Tests that the getNotifications() function when used in a document returns
|
| - // an array of the notifications which were previously displayed using the
|
| - // same Service Worker registration id, having the same filter.
|
| + // an array of the notifications which were previously displayed using a filter.
|
| + // Notifications replaced using the `tag` should not be included anymore.
|
| async_test(function(test) {
|
| var scope = 'resources/scope/' + location.pathname,
|
| script = 'instrumentation-service-worker.js';
|
| @@ -29,10 +29,10 @@
|
| }).then(function() {
|
| return registration.showNotification('Hello again, world!', {
|
| body: 'Second notification',
|
| - tag: 'strawberry',
|
| + tag: 'banana',
|
| });
|
| }).then(function() {
|
| - return registration.getNotifications({ tag: 'strawberry' });
|
| + return registration.getNotifications({ tag: 'banana' });
|
| }).then(function(notifications) {
|
| assert_equals(notifications.length, 1);
|
|
|
| @@ -42,7 +42,7 @@
|
| test.done();
|
| }).catch(unreached_rejection(test));
|
|
|
| - }, 'ServiceWorkerRegistration.getNotifications() returns the opened notifications with the same filter.');
|
| + }, 'ServiceWorkerRegistration.getNotifications() does not return replaced notifications.');
|
| </script>
|
| </body>
|
| </html>
|
|
|