Skip to content

hikeeba/jest-nunit-reporter

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

51 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status npm

jest-nunit-reporter

A NUnit test reporter for Jest.

Installation

$ npm i -D jest-nunit-reporter

Usage

In your package.json file include a "jest" config section and specify the "testResultsProcessor":

{
  "jest": {
    "testResultsProcessor": "./node_modules/jest-nunit-reporter"
  }
}

For your Continuous Integration you can simply do:

jest --ci --testResultsProcessor="./node_modules/jest-nunit-reporter

The reporter will generate a test-report.xml file in the project root. If you need to specify a different location(e.g., for a CI server) then set the paths in the package.json jestNunitReporter property:

"jestNunitReporter": {
  "outputPath": "reports/",
  "outputFileName": "custom-report.xml",
}

There are other options for naming test suites:

  • testSuiteNamePrefix: Add prefix to test-suites names
  • testSuiteNameFromAncestors: Use ancestors root title (describe)

LICENSE

MIT

About

A NUnit test reporter for Jest.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%