OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 GEN_INCLUDE([ | 5 GEN_INCLUDE([ |
6 'common.js', | 6 'common.js', |
7 'callback_helper.js']); | 7 'callback_helper.js']); |
8 | 8 |
9 /** | 9 /** |
10 * Base test fixture for ChromeVox end to end tests. | 10 * Base test fixture for ChromeVox end to end tests. |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 */}); | 43 */}); |
44 }, | 44 }, |
45 | 45 |
46 /** @override */ | 46 /** @override */ |
47 testGenPreamble: function() { | 47 testGenPreamble: function() { |
48 GEN_BLOCK(function() {/*! | 48 GEN_BLOCK(function() {/*! |
49 base::Closure load_cb = | 49 base::Closure load_cb = |
50 base::Bind(&chromeos::AccessibilityManager::EnableSpokenFeedback, | 50 base::Bind(&chromeos::AccessibilityManager::EnableSpokenFeedback, |
51 base::Unretained(chromeos::AccessibilityManager::Get()), | 51 base::Unretained(chromeos::AccessibilityManager::Get()), |
52 true, | 52 true, |
53 ui::A11Y_NOTIFICATION_NONE); | 53 ash::A11Y_NOTIFICATION_NONE); |
54 WaitForExtension(extension_misc::kChromeVoxExtensionId, load_cb); | 54 WaitForExtension(extension_misc::kChromeVoxExtensionId, load_cb); |
55 */}); | 55 */}); |
56 }, | 56 }, |
57 | 57 |
58 /** | 58 /** |
59 * Launch a new tab, wait until tab status complete, then run callback. | 59 * Launch a new tab, wait until tab status complete, then run callback. |
60 * @param {function() : void} doc Snippet wrapped inside of a function. | 60 * @param {function() : void} doc Snippet wrapped inside of a function. |
61 * @param {function()} callback Called once the document is ready. | 61 * @param {function()} callback Called once the document is ready. |
62 */ | 62 */ |
63 runWithLoadedTab: function(doc, callback) { | 63 runWithLoadedTab: function(doc, callback) { |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
110 * called. If this method is called one or more times, then | 110 * called. If this method is called one or more times, then |
111 * {@code testDone()} will be called when all callbacks have been called. | 111 * {@code testDone()} will be called when all callbacks have been called. |
112 * @param {Function=} opt_callback Wrapped callback that will have its this | 112 * @param {Function=} opt_callback Wrapped callback that will have its this |
113 * reference bound to the test fixture. | 113 * reference bound to the test fixture. |
114 * @return {Function} | 114 * @return {Function} |
115 */ | 115 */ |
116 newCallback: function(opt_callback) { | 116 newCallback: function(opt_callback) { |
117 return this.callbackHelper_.wrap(opt_callback); | 117 return this.callbackHelper_.wrap(opt_callback); |
118 } | 118 } |
119 }; | 119 }; |
OLD | NEW |