Skip to content

Commit

Permalink
linted skip_passed and verbose reporters
Browse files Browse the repository at this point in the history
  • Loading branch information
BryanDonovan committed Nov 27, 2011
1 parent 677ec92 commit 5141ae5
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 6 deletions.
2 changes: 2 additions & 0 deletions Makefile
Expand Up @@ -24,7 +24,9 @@ LINT_FILES = ./index.js \
./lib/reporters/junit.js \
./lib/reporters/minimal.js \
./lib/reporters/nested.js \
./lib/reporters/skip_passed.js \
./lib/reporters/tap.js \
./lib/reporters/verbose.js \
./lib/track.js \
./lib/types.js \
./lib/utils.js \
Expand Down
4 changes: 3 additions & 1 deletion lib/reporters/skip_passed.js
Expand Up @@ -101,7 +101,9 @@ exports.run = function (files, options, callback) {
);
}

if (callback) callback(assertions.failures() ? new Error('We have got test failures.') : undefined);
if (callback) {
callback(assertions.failures() ? new Error('We have got test failures.') : undefined);
}
}
});
};
10 changes: 5 additions & 5 deletions lib/reporters/verbose.js
Expand Up @@ -12,14 +12,14 @@ var nodeunit = require('../nodeunit'),
utils = require('../utils'),
fs = require('fs'),
track = require('../track'),
path = require('path');
path = require('path'),
AssertionError = require('../assert').AssertionError;

/**
* Reporter info string
*/

exports.info = "Verbose tests reporter"
exports.info = "Verbose tests reporter";


/**
Expand Down Expand Up @@ -62,8 +62,8 @@ exports.run = function (files, options) {
console.log(error(bold(
'FAILURES: Undone tests (or their setups/teardowns): '
)));
var names = tracker.names();
for (var i = 0; i < names.length; i += 1) {
var i, names = tracker.names();
for (i = 0; i < names.length; i += 1) {
console.log('- ' + names[i]);
}
console.log('');
Expand Down Expand Up @@ -99,7 +99,7 @@ exports.run = function (files, options) {
});
},
done: function (assertions, end) {
var end = end || new Date().getTime();
end = end || new Date().getTime();
var duration = end - start;
if (assertions.failures()) {
console.log(
Expand Down

0 comments on commit 5141ae5

Please sign in to comment.