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

Side by Side Diff: chrome/test/data/extensions/api_test/tts/chromeos/test.js

Issue 3640001: Refactored TTS extension code so that the platform-specific TTS... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 2 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
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // TTS api test for Chrome. This is currently limited to ChromeOS. 5 // TTS api test for Chrome on ChromeOS.
6 // browser_tests.exe --gtest_filter=ExtensionApiTest.Tts 6 // browser_tests.exe --gtest_filter=ExtensionApiTest.TtsOnChromeOs
7 7
8 chrome.test.runTests([ 8 chrome.test.runTests([
9 function testSpeak() { 9 function testSpeak() {
10 chrome.experimental.tts.speak('hello world', {}, function() { 10 chrome.experimental.tts.speak('hello world', {}, function() {
11 chrome.test.succeed(); 11 chrome.test.succeed();
12 }); 12 });
13 }, 13 },
14 14
15 function testStop() { 15 function testStop() {
16 chrome.experimental.tts.stop(); 16 chrome.experimental.tts.stop();
17 chrome.test.succeed(); 17 chrome.test.succeed();
18 }, 18 },
19 19
20 function testIsSpeaking() { 20 function testIsSpeaking() {
21 for (var i = 0; i < 3; i++) { 21 for (var i = 0; i < 3; i++) {
22 chrome.experimental.tts.isSpeaking(function(speaking) { 22 chrome.experimental.tts.isSpeaking(function(speaking) {
23 chrome.test.assertTrue(speaking); 23 chrome.test.assertTrue(speaking);
24 }); 24 });
25 } 25 }
26 chrome.experimental.tts.isSpeaking(function(speaking) { 26 chrome.experimental.tts.isSpeaking(function(speaking) {
27 chrome.test.assertFalse(speaking); 27 chrome.test.assertFalse(speaking);
28 chrome.test.succeed(); 28 chrome.test.succeed();
29 }); 29 });
30 } 30 }
31 ]); 31 ]);
OLDNEW
« no previous file with comments | « chrome/test/data/extensions/api_test/tts/chromeos/test.html ('k') | chrome/test/data/extensions/api_test/tts/manifest.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698