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

Side by Side Diff: chrome/browser/resources/chromeos/braille_ime/braille_ime_unittest.gtestjs

Issue 1150173003: Fix some JS style nits. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: merge Created 5 years, 6 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
« no previous file with comments | « no previous file | chrome/browser/resources/chromeos/chromevox/braille/braille_input_handler_test.unitjs » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 /** 5 /**
6 * @fileoverview Unit test for the Braille IME. 6 * @fileoverview Unit test for the Braille IME.
7 */ 7 */
8 8
9 /** 9 /**
10 * Mock Chrome event supporting one listener. 10 * Mock Chrome event supporting one listener.
(...skipping 27 matching lines...) Expand all
38 }; 38 };
39 39
40 /** 40 /**
41 * Mock port that supports the {@code onMessage} and {@code onDisconnect} 41 * Mock port that supports the {@code onMessage} and {@code onDisconnect}
42 * events as well as {@code postMessage}. 42 * events as well as {@code postMessage}.
43 * @constructor. 43 * @constructor.
44 */ 44 */
45 function MockPort() { 45 function MockPort() {
46 this.onMessage = new MockEvent(); 46 this.onMessage = new MockEvent();
47 this.onDisconnect = new MockEvent(); 47 this.onDisconnect = new MockEvent();
48 /** @type {Array.<Object>} */ 48 /** @type {Array<Object>} */
49 this.messages = []; 49 this.messages = [];
50 } 50 }
51 51
52 MockPort.prototype = { 52 MockPort.prototype = {
53 /** 53 /**
54 * Stores {@code message} in this object. 54 * Stores {@code message} in this object.
55 * @param {Object} message Message to store. 55 * @param {Object} message Message to store.
56 */ 56 */
57 postMessage: function(message) { 57 postMessage: function(message) {
58 this.messages.push(message); 58 this.messages.push(message);
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
302 sendSetUncommitted(' there!'); 302 sendSetUncommitted(' there!');
303 sendCommitUncommitted(CONTEXT_ID + 1); 303 sendCommitUncommitted(CONTEXT_ID + 1);
304 assertEquals('Hello', text); 304 assertEquals('Hello', text);
305 305
306 sendSetUncommitted(' you!'); 306 sendSetUncommitted(' you!');
307 assertFalse(this.sendKeyDown('KeyY')); 307 assertFalse(this.sendKeyDown('KeyY'));
308 assertEquals('Hello you!', text); 308 assertEquals('Hello you!', text);
309 assertFalse(this.sendKeyUp('KeyY')); 309 assertFalse(this.sendKeyUp('KeyY'));
310 assertEquals('Hello you!', text); 310 assertEquals('Hello you!', text);
311 }); 311 });
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/resources/chromeos/chromevox/braille/braille_input_handler_test.unitjs » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698