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

Side by Side Diff: chrome/test/data/webui/settings/device_page_tests.js

Issue 2617533003: MD Settings: change most checkboxes to toggles (leave dialogs alone) (Closed)
Patch Set: fix tests Created 3 years, 11 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 cr.define('device_page_tests', function() { 5 cr.define('device_page_tests', function() {
6 /** @enum {string} */ 6 /** @enum {string} */
7 var TestNames = { 7 var TestNames = {
8 DevicePage: 'device page', 8 DevicePage: 'device page',
9 Display: 'display', 9 Display: 'display',
10 Keyboard: 'keyboard', 10 Keyboard: 'keyboard',
(...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after
267 assertLT(0, pointersPage.$.mouse.offsetHeight); 267 assertLT(0, pointersPage.$.mouse.offsetHeight);
268 assertLT(0, pointersPage.$.touchpad.offsetHeight); 268 assertLT(0, pointersPage.$.touchpad.offsetHeight);
269 assertLT(0, pointersPage.$$('#mouse h2').offsetHeight); 269 assertLT(0, pointersPage.$$('#mouse h2').offsetHeight);
270 assertLT(0, pointersPage.$$('#touchpad h2').offsetHeight); 270 assertLT(0, pointersPage.$$('#touchpad h2').offsetHeight);
271 }); 271 });
272 }); 272 });
273 273
274 test('mouse', function() { 274 test('mouse', function() {
275 expectLT(0, pointersPage.$.mouse.offsetHeight); 275 expectLT(0, pointersPage.$.mouse.offsetHeight);
276 276
277 expectFalse(pointersPage.$$('#mouse settings-checkbox').checked); 277 expectFalse(pointersPage.$$('#mouse settings-toggle-button').checked);
278 278
279 var slider = assert(pointersPage.$$('#mouse cr-slider')); 279 var slider = assert(pointersPage.$$('#mouse cr-slider'));
280 expectEquals(4, slider.value); 280 expectEquals(4, slider.value);
281 MockInteractions.pressAndReleaseKeyOn(slider.$.slider, 37 /* left */); 281 MockInteractions.pressAndReleaseKeyOn(slider.$.slider, 37 /* left */);
282 expectEquals(3, devicePage.prefs.settings.mouse.sensitivity2.value); 282 expectEquals(3, devicePage.prefs.settings.mouse.sensitivity2.value);
283 283
284 pointersPage.set('prefs.settings.mouse.sensitivity2.value', 5); 284 pointersPage.set('prefs.settings.mouse.sensitivity2.value', 5);
285 expectEquals(5, slider.value); 285 expectEquals(5, slider.value);
286 }); 286 });
287 287
(...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after
524 expectTrue(displayPage.showMirror_(displayPage.displays)); 524 expectTrue(displayPage.showMirror_(displayPage.displays));
525 expectTrue(displayPage.isMirrored_(displayPage.displays)); 525 expectTrue(displayPage.isMirrored_(displayPage.displays));
526 }); 526 });
527 }); 527 });
528 }); 528 });
529 529
530 return { 530 return {
531 TestNames: TestNames 531 TestNames: TestNames
532 }; 532 };
533 }); 533 });
OLDNEW
« no previous file with comments | « chrome/test/data/webui/settings/date_time_page_tests.js ('k') | chrome/test/data/webui/settings/metrics_reporting_tests.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698