OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // Called by the common.js module. | 4 // Called by the common.js module. |
5 function moduleDidLoad() { | 5 function moduleDidLoad() { |
6 // The module is not hidden by default so we can easily see if the plugin | 6 // The module is not hidden by default so we can easily see if the plugin |
7 // failed to load. | 7 // failed to load. |
8 common.hideModule(); | 8 common.hideModule(); |
9 } | 9 } |
10 | 10 |
(...skipping 28 matching lines...) Expand all Loading... |
39 | 39 |
40 function endCommand(testName, testResult) { | 40 function endCommand(testName, testResult) { |
41 var testRowEl = currentTestEl.querySelector('.row'); | 41 var testRowEl = currentTestEl.querySelector('.row'); |
42 var testResultEl = currentTestEl.querySelector('.result'); | 42 var testResultEl = currentTestEl.querySelector('.result'); |
43 testRowEl.classList.add(testResult); | 43 testRowEl.classList.add(testResult); |
44 testResultEl.textContent = testResult; | 44 testResultEl.textContent = testResult; |
45 } | 45 } |
46 | 46 |
47 function testendCommand() { | 47 function testendCommand() { |
48 testsFinished = true; | 48 testsFinished = true; |
49 common.removeModule(); | |
50 | 49 |
51 if (failedTests) { | 50 if (failedTests) { |
52 common.updateStatus('FAILED'); | 51 common.updateStatus('FAILED'); |
53 document.getElementById('statusField').classList.add('failed'); | 52 document.getElementById('statusField').classList.add('failed'); |
54 } else { | 53 } else { |
55 common.updateStatus('OK'); | 54 common.updateStatus('OK'); |
56 document.getElementById('statusField').classList.add('ok'); | 55 document.getElementById('statusField').classList.add('ok'); |
57 } | 56 } |
58 } | 57 } |
59 | 58 |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 argList = argList.substr(comma + 1); | 91 argList = argList.substr(comma + 1); |
93 } | 92 } |
94 args.push(arg); | 93 args.push(arg); |
95 } | 94 } |
96 | 95 |
97 // Last argument is the rest of the message. | 96 // Last argument is the rest of the message. |
98 args.push(argList); | 97 args.push(argList); |
99 | 98 |
100 cmdFunction.apply(null, args); | 99 cmdFunction.apply(null, args); |
101 } | 100 } |
OLD | NEW |