Reputation: 1305
I'm using Hapi with Good on a small project and want to disable some logs while testing (process.env.NODE_ENV == 'test'
).
This is my Good
configuration:
reporters: {
console: [{
module: 'good-console',
}, 'stdout']
}
And this is the test output:
➜ npm test
Index Route
✓ is ok
160622/214344.247, [response] http://paulodiovani-ideapad:3001: get / {} 200 (27ms)
How can I disable all logs, except error
?
Upvotes: 0
Views: 722
Reputation: 1591
Can you post your good
configuration? you probably want something like:
reporters: {
console: [
{
module: 'good-squeeze',
name: 'Squeeze',
args: [{error: '*'}]
},
{
module: 'good-console'
},
'stderr']
}
Upvotes: 2