Skip to content
This repository has been archived by the owner on Oct 4, 2022. It is now read-only.

Pharb/mocha-junit-reporter

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

#JUnit Reporter for Mocha Build Status

Produces JUnit-style XML test results.

Installation

$ npm install mocha-junit-reporter --save-dev

or as a global module

$ npm install -g mocha-junit-reporter

Usage

Run mocha with mocha-junit-reporter:

$ mocha test --reporter mocha-junit-reporter

This will output a results file at ./test-results.xml. You may optionally declare an alternate location for results XML file by setting the command line argument MOCHA_FILE or mochaFile in reporterOptions:

$ MOCHA_FILE=./path_to_your/file.xml mocha test --reporter mocha-junit-reporter

or

var mocha = new Mocha({
    reporter: 'mocha-junit-reporter',
    reporterOptions: {
        mochaFile: './path_to_your/file.xml'
    }
});

About

A JUnit XML reporter for mocha.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%