Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / http / tests / serviceworker / chromium / resources / resolve-after-window-close.html
blob4f289aa8d2e44423c62e9f4bd0c39dbb8a34b0da
1 <html>
2 <script>
3 var scope = 'empty';
5 navigator.serviceWorker.getRegistration(scope)
6 .then(function(registration) {
7 if (registration)
8 return registration.unregister();
9 })
10 .then(function() {
11 var promise = navigator.serviceWorker.register('empty-worker.js',
12 { scope: scope });
13 window.close();
14 window.opener.done();
15 });
16 </script>
17 </html>