Index: chrome/test/data/extensions/api_test/webintent_handler/background.js |
diff --git a/chrome/test/data/extensions/api_test/webintent_handler/background.js b/chrome/test/data/extensions/api_test/webintent_handler/background.js |
deleted file mode 100644 |
index 2cd36b87dad0d8858db5a382b09c5de755537d8e..0000000000000000000000000000000000000000 |
--- a/chrome/test/data/extensions/api_test/webintent_handler/background.js |
+++ /dev/null |
@@ -1,33 +0,0 @@ |
-// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
-// Use of this source code is governed by a BSD-style license that can be |
-// found in the LICENSE file. |
- |
-/* |
-This extension is a platform app that provides a Web Intent handler; it accepts |
-incoming requests and invokes chrome.test.succeed() immediately. |
-*/ |
- |
-function launchedListener(launchData) { |
- chrome.test.assertFalse(!launchData, "No launchData"); |
- chrome.test.assertFalse(!launchData.intent, "No launchData.intent"); |
- chrome.test.assertEq(launchData.intent.action, |
- "http://webintents.org/view"); |
- chrome.test.assertEq(launchData.intent.type, |
- "chrome-extension://fileentry"); |
- chrome.test.assertFalse(!launchData.intent.data, |
- "No launchData.intent.data"); |
- |
- launchData.intent.data.file(function(file) { |
- var reader = new FileReader(); |
- reader.onloadend = function(e) { |
- chrome.test.assertEq("hello, world!", reader.result); |
- chrome.test.succeed(); |
- }; |
- reader.onerror = function(e) { |
- chrome.test.fail("Error reading file contents."); |
- }; |
- reader.readAsText(file); |
- }); |
-} |
- |
-chrome.app.runtime.onLaunched.addListener(launchedListener); |