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

Side by Side Diff: chrome/test/data/extensions/api_test/webrequest_extensions/extension/contentscript.js

Issue 1267183003: Hide requests in an extension from other extensions (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update comment in operator<, remove blank line, OOPIF-friendly test 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // location.origin will be equivalent to 'http://example.com:PORT';
6 var baseUrl = location.origin;
7
8 chrome.test.sendMessage('contentscript_ready', function() {
9 var x = new XMLHttpRequest();
10 x.open('GET', baseUrl + '/extensions/test_file.txt?contentscript');
11 x.onloadend = function() {
12 chrome.test.assertEq('Hello!', x.responseText);
13
14 chrome.test.sendMessage('contentscript_done', function() {
15 var frame = document.createElement('iframe');
16 frame.src = chrome.runtime.getURL('frame.html');
17 document.body.appendChild(frame);
18 });
19 };
20 x.send();
21 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698