Index: chrome/test/chromedriver/extension/background.js |
diff --git a/chrome/test/chromedriver/extension/background.js b/chrome/test/chromedriver/extension/background.js |
index 9158d6f5d72672bafc3bf7260cfe83d7771ebddb..9655ffa72b7f6d27cc51d67156dccc9a387e81ed 100644 |
--- a/chrome/test/chromedriver/extension/background.js |
+++ b/chrome/test/chromedriver/extension/background.js |
@@ -71,3 +71,18 @@ function updateWindow(updateInfo, callback, errCallback) { |
}); |
}); |
} |
+ |
+/** |
+ * Launches an app with the specified id. |
+ * |
+ * @param {string} id The ID of the app to launch. |
+ * @param {function()} callback Invoked when the launch event is complete. |
+ * @param {function(!Error)} errCallback The callback to invoke for error |
+ * reporting. |
+ */ |
+function launchApp(id, callback, errCallback) { |
+ chrome.management.launchApp(id, function() { |
+ checkForExtensionError(errCallback); |
+ callback(); |
+ }); |
+} |