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

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

Issue 10332071: Pass command line arguments onto platform apps which provide the right intent. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix bad merge Created 8 years, 7 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 | Annotate | Revision Log
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 function onLaunched(launchData) {
6 chrome.test.runTests([
7 function testIntent() {
8 chrome.test.assertFalse(!launchData, "No launchData");
9 chrome.test.assertFalse(!launchData.intent, "No launchData.intent");
10 chrome.test.assertTrue(
11 launchData.intent.action == "http://webintents.org/view",
12 "launchData.intent.action incorrect: " + launchData.intent.action);
13 chrome.test.assertTrue(launchData.intent.type == "text/plain",
14 "launchData.intent.type incorrect: " + launchData.intent.type);
15 chrome.test.assertFalse(!launchData.intent.extra_data,
16 "No launchData.intent.extra_data");
17 chrome.test.assertFalse(!launchData.intent.extra_data.url,
18 "No launchData.intent.extra_data.url");
19 chrome.test.succeed();
20 }
21 ]);
22 }
23
24 chrome.experimental.app.onLaunched.addListener(onLaunched);
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698