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

Side by Side Diff: chrome/test/data/extensions/platform_apps/document_editor/test.js

Issue 9845003: Pass command line arguments onto platform apps which provide the right intent. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Include files Created 8 years, 9 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 (c) 2012 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 chrome.test.runTests([
6 function testIntent() {
7 chrome.test.assertFalse(!window.intent, "No window.intent");
8 chrome.test.assertTrue(window.intent.action == "http://webintents.org/view",
9 "window.intent.action incorrect: " + window.intent.action);
10 chrome.test.assertTrue(window.intent.type == "text/plain",
11 "window.intent.type incorrect: " + window.intent.type);
12 var request = new XMLHttpRequest();
13 request.open('GET', window.intent.data, false);
14 request.send(null);
15 chrome.test.assertTrue(request.status === 0,
16 "Invalid request.status: " + request.status);
17 chrome.test.assertTrue(
18 request.responseText.indexOf("This is a test. Word.") == 0,
19 "request.responseText incorrect: " + request.responseText);
20 chrome.test.succeed();
21 }
22 ]);
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698