Closed NetForces closed 9 years ago
It comes from console.log(tools.fail())
, it logs result of tools.fail()
call which returns undefined.
Doh !
Changed the module for:
var clc = require('/usr/lib/node_modules/cli-color');
module.exports = {
pass: function () {
return(clc.bgGreen.white.bold("PASS"));
},
fail: function () {
return(clc.bgRed.white.bold("FAIL"));
}
};
Works great. Thanks.
Here is a very simple example:
File node_functions.js:
File test.js:
The expected result would be simply the word FAIL in bold white over red backgroud.
However the result is:
I have no idea where the "undefined" comes from.
Running cli-color@1.0.0 with node v0.10.39