Expected behavior
I expect that if browserConsoleLogOptions.level === 'error', then any instance of console.log, console.debug or console.warn will not appear in my terminal.
Actual behavior
Instances of console.debug are still shown in my console, despite the following in my Karma configuration:
browserConsoleLogOptions: {
level: 'error',
format: '%b %T: %m',
terminal: true
},
Specifically, console.debug('hello there!'); results in DEBUG: 'hello there!' being printed when I run tests.
Note that switching browserConsoleLogOptions.terminal to false correctly silences all console output.
Enviroment Details
Karma 1.1.0 with Webpack 2 through Babel 6 on macOS 10.11.5 with npm 3.8.8 and node v5.11.0. Please see package.json for full requirements.
Steps to reproduce the behaviour
- Clone the example repo found at https://github.com/jambonsw/webpack2-karma-logging-error-mve
- Install the packages with
npm install
- Run tests with
npm test
Expected behavior
I expect that if
browserConsoleLogOptions.level === 'error', then any instance ofconsole.log,console.debugorconsole.warnwill not appear in my terminal.Actual behavior
Instances of
console.debugare still shown in my console, despite the following in my Karma configuration:Specifically,
console.debug('hello there!');results inDEBUG: 'hello there!'being printed when I run tests.Note that switching
browserConsoleLogOptions.terminaltofalsecorrectly silences allconsoleoutput.Enviroment Details
Karma 1.1.0 with Webpack 2 through Babel 6 on macOS 10.11.5 with npm 3.8.8 and node v5.11.0. Please see package.json for full requirements.
Steps to reproduce the behaviour
npm installnpm test