Bunyan (as of v1.8.10) doesn’t provide an explicit api to mute logging. This is especially useful when you’re running unit tests and don’t want logs and test reports to be mixed.
One workaround suggested by the author is to set the log level to a value above
Set an environment variable when running tests:
Check for it in the logger module and if it matches, set the log level above
This disables logging when running tests.