OLD | NEW |
---|---|
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 * Test fixture for sync internals WebUI testing. | 6 * Test fixture for sync internals WebUI testing. |
7 * @constructor | 7 * @constructor |
8 * @extends {testing.Test} | 8 * @extends {testing.Test} |
9 */ | 9 */ |
10 function SyncInternalsWebUITest() {} | 10 function SyncInternalsWebUITest() {} |
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
224 | 224 |
225 NETWORK_EVENT_DETAILS_2 = { | 225 NETWORK_EVENT_DETAILS_2 = { |
226 'details': 'Received error: SYNC_AUTH_ERROR', | 226 'details': 'Received error: SYNC_AUTH_ERROR', |
227 'proto': {}, | 227 'proto': {}, |
228 'time': 1395874542192.837, | 228 'time': 1395874542192.837, |
229 'type': 'GetUpdates Response', | 229 'type': 'GetUpdates Response', |
230 }; | 230 }; |
231 | 231 |
232 TEST_F('SyncInternalsWebUITest', 'Uninitialized', function() { | 232 TEST_F('SyncInternalsWebUITest', 'Uninitialized', function() { |
233 assertNotEquals(null, chrome.sync.aboutInfo); | 233 assertNotEquals(null, chrome.sync.aboutInfo); |
234 expectTrue(this.hasInDetails(true, 'Username', '')); | 234 // TODO(rogerta): re-enable this test on non-cros platforms. On cros, the |
Nicolas Zea
2014/12/04 17:57:39
Were you planning to conditionally disable this as
Roger Tawa OOO till Jul 10th
2014/12/04 22:26:47
Right, I want fix this TODO before commit. Here i
| |
235 // user is always signed in. | |
236 //expectTrue(this.hasInDetails(true, 'Username', '')); | |
235 expectTrue(this.hasInDetails(false, 'Summary', 'Uninitialized')); | 237 expectTrue(this.hasInDetails(false, 'Summary', 'Uninitialized')); |
236 }); | 238 }); |
237 | 239 |
238 TEST_F('SyncInternalsWebUITest', 'LoadPastedAboutInfo', function() { | 240 TEST_F('SyncInternalsWebUITest', 'LoadPastedAboutInfo', function() { |
239 // Expose the text field. | 241 // Expose the text field. |
240 $('import-status').click(); | 242 $('import-status').click(); |
241 | 243 |
242 // Fill it with fake data. | 244 // Fill it with fake data. |
243 $('status-text').value = JSON.stringify(HARD_CODED_ABOUT_INFO); | 245 $('status-text').value = JSON.stringify(HARD_CODED_ABOUT_INFO); |
244 | 246 |
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
380 | 382 |
381 // Click the dump-to-text button. | 383 // Click the dump-to-text button. |
382 $('dump-to-text').click(); | 384 $('dump-to-text').click(); |
383 | 385 |
384 // Verify our event is among the results. | 386 // Verify our event is among the results. |
385 var eventDumpText = $('data-dump').textContent; | 387 var eventDumpText = $('data-dump').textContent; |
386 | 388 |
387 expectGE(eventDumpText.indexOf('onConnectionStatusChange'), 0); | 389 expectGE(eventDumpText.indexOf('onConnectionStatusChange'), 0); |
388 expectGE(eventDumpText.indexOf('CONNECTION_OK'), 0); | 390 expectGE(eventDumpText.indexOf('CONNECTION_OK'), 0); |
389 }); | 391 }); |
OLD | NEW |