| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 /** @fileoverview Runs Polymer Appearance Settings elements. */ | 5 /** @fileoverview Runs Polymer Appearance Settings elements. */ |
| 6 | 6 |
| 7 GEN_INCLUDE(['settings_page_browsertest.js']); | 7 GEN_INCLUDE(['settings_page_browsertest.js']); |
| 8 | 8 |
| 9 /** | 9 /** |
| 10 * Test Polymer Appearance Settings elements. | 10 * Test Polymer Appearance Settings elements. |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 TEST_F('AppearanceSettingsBrowserTest', 'uiTests', function() { | 31 TEST_F('AppearanceSettingsBrowserTest', 'uiTests', function() { |
| 32 /** | 32 /** |
| 33 * The prefs API that will get a fake implementation. | 33 * The prefs API that will get a fake implementation. |
| 34 * @type {!SettingsPrivate} | 34 * @type {!SettingsPrivate} |
| 35 */ | 35 */ |
| 36 var settingsPrefs; | 36 var settingsPrefs; |
| 37 var self = this; | 37 var self = this; |
| 38 | 38 |
| 39 var fontSize = function() { | 39 var fontSize = function() { |
| 40 return self.appearancePage( | 40 return self.appearancePage( |
| 41 '#defaultFontSize').$$('[class=iron-selected]').textContent.trim(); | 41 '#defaultFontSize').$$('.iron-selected').textContent.trim(); |
| 42 }; | 42 }; |
| 43 | 43 |
| 44 suite('AppearanceHandler', function() { | 44 suite('AppearanceHandler', function() { |
| 45 suiteSetup(function() { | 45 suiteSetup(function() { |
| 46 settingsPrefs = document.querySelector( | 46 settingsPrefs = document.querySelector( |
| 47 'cr-settings').$$('settings-prefs'); | 47 'cr-settings').$$('settings-prefs'); |
| 48 assertTrue(!!settingsPrefs); | 48 assertTrue(!!settingsPrefs); |
| 49 return CrSettingsPrefs.initialized; | 49 return CrSettingsPrefs.initialized; |
| 50 }); | 50 }); |
| 51 | 51 |
| (...skipping 13 matching lines...) Expand all Loading... |
| 65 * etc.). | 65 * etc.). |
| 66 */ | 66 */ |
| 67 test('custom font size', function() { | 67 test('custom font size', function() { |
| 68 settingsPrefs.set( | 68 settingsPrefs.set( |
| 69 'prefs.webkit.webprefs.default_font_size.value', 19); | 69 'prefs.webkit.webprefs.default_font_size.value', 19); |
| 70 assertEquals('Custom', fontSize()); | 70 assertEquals('Custom', fontSize()); |
| 71 }); | 71 }); |
| 72 }); | 72 }); |
| 73 mocha.run(); | 73 mocha.run(); |
| 74 }); | 74 }); |
| OLD | NEW |