Reputation: 4292
If I have the scenario with 1000+ tests and want to run only selected portion of them I can use fdescribe
.
The rest of tests are skipped which is great however they still pollute the console output. How can I suppress the console output for skipped tests?
Upvotes: 22
Views: 7179
Reputation: 15789
If you're running tests via Karma, there is a spec reporter plugin that you can configure to ignore various things.
https://www.npmjs.com/package/karma-spec-reporter
https://www.npmjs.com/package/karma-spec-reporter-2
Add the following to your karma.conf.js:
...
config.set({
...
reporters: ["spec"],
specReporter: {
suppressSkipped: true, // do not print information about skipped tests
},
plugins: ["karma-spec-reporter"],
...
If you're not using Karma, then you need to find the proper Jasmine reporter and configure it, or create your own reporter.
https://www.npmjs.com/package/jasmine2-reporter
Upvotes: 29
Reputation: 7389
If you're using the mocha reporter:
reporters: ['mocha'],
mochaReporter: {
ignoreSkipped: true,
},
Upvotes: 22