Chromium Code Reviews

Unified Diff: LayoutTests/http/tests/serviceworker/chromium/resources/clients-openwindow.js

Issue 1224083008: ServiceWorker: Change a target url to open (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/http/tests/serviceworker/chromium/resources/clients-openwindow.js
diff --git a/LayoutTests/http/tests/serviceworker/chromium/resources/clients-openwindow.js b/LayoutTests/http/tests/serviceworker/chromium/resources/clients-openwindow.js
index ff2cdee57747e7ce8fc47de3e258aeebb3ccaf27..7671ba6746be3483b7485af372e95b1285e0a028 100644
--- a/LayoutTests/http/tests/serviceworker/chromium/resources/clients-openwindow.js
+++ b/LayoutTests/http/tests/serviceworker/chromium/resources/clients-openwindow.js
@@ -3,6 +3,7 @@
// This helper also exposes |client|, |postMessage()|, |runNextTestOrQuit()|,
// |synthesizeNotificationClick()| and |initialize()|.
importScripts('sw-test-helpers.js');
+importScripts('../../../resources/get-host-info.js');
var TESTS = [
function testWithNoNotificationClick() {
@@ -14,7 +15,10 @@ var TESTS = [
function testOpenCrossOriginWindow() {
synthesizeNotificationClick().then(function(e) {
- clients.openWindow('https://test.com/').then(function(c) {
+ var cross_origin_url =
+ get_host_info()['HTTP_REMOTE_ORIGIN'] +
+ '/serviceworker/chromium/resources/blank.html';
+ clients.openWindow(cross_origin_url).then(function(c) {
self.postMessage('openWindow() can open cross origin windows');
self.postMessage('openWindow() result: ' + c);
}).then(runNextTestOrQuit);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine