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
3 // found in the LICENSE file.
5 // Include test fixture.
6 GEN_INCLUDE(['net_internals_test.js']);
11 function DebugLogsStatusWatcher() {
12 NetInternalsTest.Task.call(this);
13 this.setCompleteAsync(true);
16 DebugLogsStatusWatcher.prototype = {
17 __proto__: NetInternalsTest.Task.prototype,
20 g_browser.addStoreDebugLogsObserver(this);
21 $('chromeos-view-store-debug-logs').click();
24 onStoreDebugLogs: function(status) {
25 if (status.indexOf('Created') != -1) {
26 this.onTaskDone(true);
29 if (status.indexOf('Failed') != -1) {
30 this.onTaskDone(false);
36 function ResultChecker() {
37 NetInternalsTest.Task.call(this);
40 ResultChecker.prototype = {
41 __proto__: NetInternalsTest.Task.prototype,
43 start: function(success) {
49 TEST_F('NetInternalsTest',
50 'DISABLED_netInternalsChromeOSViewStoreDebugLogs',
54 // #chromeos-view-import-onc fails accessibility check.
55 this.runAccessibilityChecks = false;
56 NetInternalsTest.switchToView('chromeos');
58 var taskQueue = new NetInternalsTest.TaskQueue(true);
59 taskQueue.addTask(new DebugLogsStatusWatcher());
60 taskQueue.addTask(new ResultChecker());
64 })(); // Anonymous namespace