Index: chrome/test/data/extensions/platform_apps/speech/background_page/test.js |
diff --git a/chrome/test/data/extensions/platform_apps/speech/background_page/test.js b/chrome/test/data/extensions/platform_apps/speech/background_page/test.js |
new file mode 100644 |
index 0000000000000000000000000000000000000000..fb2407c1b4e685e9fea5c21d30987544304b63a1 |
--- /dev/null |
+++ b/chrome/test/data/extensions/platform_apps/speech/background_page/test.js |
@@ -0,0 +1,24 @@ |
+// Copyright 2013 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. |
+ |
+chrome.app.runtime.onLaunched.addListener(function() { |
+ chrome.test.runTests([ |
+ function testWebkitSpeechRecognition() { |
+ var succeeded = false; |
+ |
+ var r = new webkitSpeechRecognition(); |
+ r.onerror = function(e) { |
+ if (succeeded) { |
+ return; |
not at google - send to devlin
2013/09/21 04:13:55
so.. you shouldn't need this anymore right? if I u
lazyboy
2013/09/21 06:07:19
This is just a safeguard. A request can start and
|
+ } |
+ chrome.test.fail(); |
+ }; |
+ r.onstart = function() { |
+ succeeded = true; |
+ chrome.test.succeed(); |
+ }; |
+ r.start(); |
+ } |
+ ]); |
+}); |