| Index: third_party/WebKit/LayoutTests/external/wpt/service-workers/service-worker/skip-waiting-installed.https.html
|
| diff --git a/third_party/WebKit/LayoutTests/external/wpt/service-workers/service-worker/skip-waiting-installed.https.html b/third_party/WebKit/LayoutTests/external/wpt/service-workers/service-worker/skip-waiting-installed.https.html
|
| index 795386f8cd6747c6b551195c9bfed9eda5c307ea..93dc06d103378ef908a7470a2287fe06ef3177d7 100644
|
| --- a/third_party/WebKit/LayoutTests/external/wpt/service-workers/service-worker/skip-waiting-installed.https.html
|
| +++ b/third_party/WebKit/LayoutTests/external/wpt/service-workers/service-worker/skip-waiting-installed.https.html
|
| @@ -1,10 +1,10 @@
|
| <!DOCTYPE html>
|
| <title>Service Worker: Skip waiting installed worker</title>
|
| <script src="/resources/testharness.js"></script>
|
| -<script src="resources/testharness-helpers.js"></script>
|
| <script src="/resources/testharnessreport.js"></script>
|
| <script src="resources/test-helpers.sub.js"></script>
|
| <script>
|
| +'use strict';
|
|
|
| promise_test(function(t) {
|
| var scope = 'resources/blank.html?skip-waiting-installed';
|
| @@ -13,16 +13,17 @@ promise_test(function(t) {
|
| var frame, frame_sw, service_worker, registration, onmessage, oncontrollerchanged;
|
| var saw_message = new Promise(function(resolve) {
|
| onmessage = function(e) {
|
| - var message = e.data;
|
| - assert_equals(
|
| - message, 'PASS',
|
| - 'skipWaiting promise should be resolved with undefined');
|
| + resolve(e.data);
|
| + };
|
| + })
|
| + .then(function(message) {
|
| + assert_equals(
|
| + message, 'PASS',
|
| + 'skipWaiting promise should be resolved with undefined');
|
|
|
| - assert_equals(registration.active.scriptURL, normalizeURL(url2),
|
| - "skipWaiting should make worker become active");
|
| - resolve();
|
| - };
|
| - });
|
| + assert_equals(registration.active.scriptURL, normalizeURL(url2),
|
| + 'skipWaiting should make worker become active');
|
| + });
|
| var saw_controllerchanged = new Promise(function(resolve) {
|
| oncontrollerchanged = function() {
|
| assert_equals(
|
|
|