| OLD | NEW |
| 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 /** | 5 /** |
| 6 * @fileoverview Tests for chrome://bluetooth-internals | 6 * @fileoverview Tests for chrome://bluetooth-internals |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 /** @const {string} Path to source root. */ | 9 /** @const {string} Path to source root. */ |
| 10 var ROOT_PATH = '../../../../'; | 10 var ROOT_PATH = '../../../../'; |
| (...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 151 this.adapterFactory = new TestAdapterFactoryProxy(); | 151 this.adapterFactory = new TestAdapterFactoryProxy(); |
| 152 bindings.StubBindings(stub).delegate = this.adapterFactory; | 152 bindings.StubBindings(stub).delegate = this.adapterFactory; |
| 153 | 153 |
| 154 this.setupResolver.resolve(); | 154 this.setupResolver.resolve(); |
| 155 }.bind(this)); | 155 }.bind(this)); |
| 156 }.bind(this)); | 156 }.bind(this)); |
| 157 }.bind(this); | 157 }.bind(this); |
| 158 }, | 158 }, |
| 159 }; | 159 }; |
| 160 | 160 |
| 161 TEST_F('BluetoothInternalsTest', 'Startup_BluetoothInternals', function() { | 161 // Times out on chromium.mac/Mac10.11 Tests. See https://crbug.com/667970. |
| 162 GEN('#if defined(OS_MACOSX)'); |
| 163 GEN('#define MAYBE_Startup_BluetoothInternals ' + |
| 164 'DISABLED_Startup_BluetoothInternals'); |
| 165 GEN('#else'); |
| 166 GEN('#define MAYBE_Startup_BluetoothInternals Startup_BluetoothInternals'); |
| 167 GEN('#endif'); |
| 168 |
| 169 TEST_F('BluetoothInternalsTest', 'MAYBE_Startup_BluetoothInternals', |
| 170 function() { |
| 162 var fakeAdapterInfo = { | 171 var fakeAdapterInfo = { |
| 163 address: '02:1C:7E:6A:11:5A', | 172 address: '02:1C:7E:6A:11:5A', |
| 164 discoverable: false, | 173 discoverable: false, |
| 165 discovering: false, | 174 discovering: false, |
| 166 initialized: true, | 175 initialized: true, |
| 167 name: 'computer.example.com-0', | 176 name: 'computer.example.com-0', |
| 168 powered: true, | 177 powered: true, |
| 169 present: true, | 178 present: true, |
| 170 }; | 179 }; |
| 171 | 180 |
| (...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 386 var newDeviceInfo3 = Object.assign({}, fakeDeviceInfo3); | 395 var newDeviceInfo3 = Object.assign({}, fakeDeviceInfo3); |
| 387 newDeviceInfo3.rssi = {value: -17}; | 396 newDeviceInfo3.rssi = {value: -17}; |
| 388 adapterBroker.adapterClient_.deviceChanged(newDeviceInfo3); | 397 adapterBroker.adapterClient_.deviceChanged(newDeviceInfo3); |
| 389 expectEquals('-17', rssiColumn.textContent); | 398 expectEquals('-17', rssiColumn.textContent); |
| 390 }); | 399 }); |
| 391 }); | 400 }); |
| 392 | 401 |
| 393 // Run all registered tests. | 402 // Run all registered tests. |
| 394 mocha.run(); | 403 mocha.run(); |
| 395 }); | 404 }); |
| OLD | NEW |