0.1.1 • Published 11 years ago
karma-testng-reporter v0.1.1
karma-testng-reporter
Reporter for the TestNG XML format.
Installation
The easiest way is to keep karma-testng-reporter as a devDependency in your package.json.
{
"devDependencies": {
"karma": "~0.10",
"karma-testng-reporter": "0.1"
}
}You can simple do it by:
npm install karma-testng-reporter --save-devConfiguration
// karma.conf.js
module.exports = function(config) {
config.set({
reporters: ['progress', 'testng'],
// the default configuration
testngReporter: {
outputFile: 'unit/testng-results.xml',
suite: ''
}
});
};If you want to tag your test cases you can simply put the tag names separated with '|' in the describe section . e.g. describe('Logger Module|UT|CT',function(){}); This will tag the specs present inside the describe with two tags UT and CT. As many number of tags can be added. You can pass list of reporters as a CLI argument too:
karma start --reporters testng,dotsFor more information on Karma see the homepage.