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

Unified Diff: third_party/WebKit/LayoutTests/http/tests/serviceworker/chromium/resources/navigation-preload-origin-trial-interfaces-worker.php

Issue 2627023002: Introduce Origin-Trial for Service Worker Navigation Preload (Closed)
Patch Set: s/an/a Created 3 years, 11 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
Index: third_party/WebKit/LayoutTests/http/tests/serviceworker/chromium/resources/navigation-preload-origin-trial-interfaces-worker.php
diff --git a/third_party/WebKit/LayoutTests/http/tests/serviceworker/chromium/resources/navigation-preload-origin-trial-interfaces-worker.php b/third_party/WebKit/LayoutTests/http/tests/serviceworker/chromium/resources/navigation-preload-origin-trial-interfaces-worker.php
new file mode 100644
index 0000000000000000000000000000000000000000..6b8032d747e1cfb4d0b03945c4067515dc4c409e
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/http/tests/serviceworker/chromium/resources/navigation-preload-origin-trial-interfaces-worker.php
@@ -0,0 +1,17 @@
+<?php
+if (isset($_GET["origintrial"])) {
+ // generate_token.py http://127.0.0.1:8000 ServiceWorkerNavigationPreload -expire-timestamp=2000000000
+ header("Origin-Trial: AsAA4dg2Rm+GSgnpyxxnpVk1Bk8CcE+qVBTDpPbIFNscyNRJOdqw1l0vkC4dtsGm1tmP4ZDAKwycQDzsc9xr7gMAAABmeyJvcmlnaW4iOiAiaHR0cDovLzEyNy4wLjAuMTo4MDAwIiwgImZlYXR1cmUiOiAiU2VydmljZVdvcmtlck5hdmlnYXRpb25QcmVsb2FkIiwgImV4cGlyeSI6IDIwMDAwMDAwMDB9");
+}
+header('Content-Type: application/javascript');
+?>
+importScripts('./get-interface-names.js');
+
+self.addEventListener('message', event => {
+ event.source.postMessage(
+ get_interface_names(
+ this,
+ ['NavigationPreloadManager',
+ 'FetchEvent',
+ 'ServiceWorkerRegistration']));
+ });

Powered by Google App Engine
This is Rietveld 408576698