diff --git a/lib/jsdoc/util/logger.js b/lib/jsdoc/util/logger.js index df644fa5..65dae91b 100644 --- a/lib/jsdoc/util/logger.js +++ b/lib/jsdoc/util/logger.js @@ -133,7 +133,7 @@ function wrapLogFunction(name, func) { function printToStdout() { var args = Array.prototype.slice.call(arguments, 0); - util.print( util.format.apply(util, args) ); + process.stdout.write( util.format.apply(util, args) ); } /** diff --git a/test/jasmine-jsdoc.js b/test/jasmine-jsdoc.js index 7ebe68fd..984604e8 100644 --- a/test/jasmine-jsdoc.js +++ b/test/jasmine-jsdoc.js @@ -50,7 +50,6 @@ jasmine.initialize = function(done, verbose) { } var reporterOpts = { - print: util.print, color: env.opts.nocolor === true ? false : true, onComplete: done }; diff --git a/test/reporter.js b/test/reporter.js index 5e4e36c2..b4d0ca06 100644 --- a/test/reporter.js +++ b/test/reporter.js @@ -1,4 +1,6 @@ module.exports = function(jasmine) { + var util = require('util'); + var jasmineNode = {}; // @@ -32,7 +34,7 @@ module.exports = function(jasmine) { }; jasmineNode.TerminalReporter = function(config) { - this.print_ = config.print || print; + this.print_ = config.print || function (str) { process.stdout.write(util.format(str)); }; this.color_ = config.color ? jasmineNode.ANSIColors : jasmineNode.NoColors; this.started_ = false; @@ -152,10 +154,10 @@ module.exports = function(jasmine) { reportSpecResults : function(spec) { var result = spec.results(); var msg = ''; - if (result.passed()) { + if (result.skipped) { + msg = this.stringWithColor_('-', this.color_.ignore()); + } else if (result.passed()) { msg = this.stringWithColor_('.', this.color_.pass()); - // } else if (result.skipped) { TODO: Research why "result.skipped" returns false when "xit" is called on a spec? - // msg = (colors) ? (ansi.yellow + '*' + ansi.none) : '*'; } else { msg = this.stringWithColor_('F', this.color_.fail()); this.addFailureToFailures_(spec);