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

Unified Diff: LayoutTests/http/tests/serviceworker/resources/register.html

Issue 1312723002: Service workers: Add test for HTTP to HTTPS redirect (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: wait for unregister Created 5 years, 4 months 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 | « LayoutTests/http/tests/serviceworker/http-to-https-redirect-and-register.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/http/tests/serviceworker/resources/register.html
diff --git a/LayoutTests/http/tests/serviceworker/resources/register.html b/LayoutTests/http/tests/serviceworker/resources/register.html
new file mode 100644
index 0000000000000000000000000000000000000000..e8713dd702cba62e48996581cd5734a83f7e9c71
--- /dev/null
+++ b/LayoutTests/http/tests/serviceworker/resources/register.html
@@ -0,0 +1,20 @@
+<!doctype html>
+<title>register</title>
+<script src="test-helpers.js"></script>
+<body>
+<script>
+navigator.serviceWorker.register('empty-worker.js', {scope: 'scope-register'})
+ .then(
+ registration => {
+ registration.unregister().then(() => {
+ window.parent.postMessage('OK', '*');
+ });
+ },
+ error => {
+ window.parent.postMessage('FAIL: ' + error.name, '*');
+ })
+ .catch(error => {
+ window.parent.postMessage('ERROR: ' + error.name, '*');
+ });
+</script>
+</body>
« no previous file with comments | « LayoutTests/http/tests/serviceworker/http-to-https-redirect-and-register.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698