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

Unified Diff: chrome/test/data/extensions/api_test/webrequest_extensions/app/background.js

Issue 1267183003: Hide requests in an extension from other extensions (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix tests, add TODO for ExtensionWebRequestEventRouter::OnEventHandled 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
Index: chrome/test/data/extensions/api_test/webrequest_extensions/app/background.js
diff --git a/chrome/test/data/extensions/api_test/webrequest_extensions/app/background.js b/chrome/test/data/extensions/api_test/webrequest_extensions/app/background.js
new file mode 100644
index 0000000000000000000000000000000000000000..8a418192e3af4e1285ff57fbc77187cbce5170f9
--- /dev/null
+++ b/chrome/test/data/extensions/api_test/webrequest_extensions/app/background.js
@@ -0,0 +1,17 @@
+// Copyright (c) 2015 The Chromium Authors. All rights reserved.
not at google - send to devlin 2015/08/04 20:27:02 (c) is not needed
robwu 2015/08/04 21:57:24 Done.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+chrome.test.getConfig(function(config) {
+ var baseUrl = 'http://example.com:' + config.testServer.port;
lazyboy 2015/08/04 15:59:26 nit: Indent 2 spaces in this CL.
not at google - send to devlin 2015/08/04 20:27:02 yep, here and the JS in the other files as well.
robwu 2015/08/04 21:57:24 Done.
+
+ var x = new XMLHttpRequest();
+ x.open('GET', baseUrl + '/extensions/test_file.txt?app');
+ x.onloadend = function() {
+ // Just a sanity check to ensure that the server is running.
+ // The test does not change the response.
+ chrome.test.assertEq('Hello!', x.responseText);
+ chrome.test.sendMessage('app_done');
+ };
+ x.send();
+});

Powered by Google App Engine
This is Rietveld 408576698