avoid logs polluting the unit test output

This commit is contained in:
El RIDO 2017-10-30 07:04:59 +01:00
parent 751731414e
commit 29419d03cd
No known key found for this signature in database
GPG key ID: 0F5C940A6BD81F92
4 changed files with 12 additions and 12 deletions

View file

@ -25,8 +25,8 @@ global.RawDeflate.inflate = require('./rawinflate-0.3').RawDeflate.inflate;
require('./privatebin');
// redirect console messages to log file
console.warn = console.error = function (msg) {
logFile.write(msg + '\n');
console.info = console.warn = console.error = function () {
logFile.write(Array.prototype.slice.call(arguments).join('') + '\n');
}
describe('Helper', function () {