Skip to content

sa-0001/tap-teamcity-js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

@sa0001/tap-teamcity

[NPM][https://www.npmjs.com/package/@sa0001/tap-teamcity]

This module converts the TAP-format output of running tap, to the Junit-format expected by Teamcity.

Install

npm install @sa0001/tap-teamcity

Usage

It can be run from the command line, in which case it reads from stdin and writes to stdout:

./node_modules/.bin/tap ./test.js > ./test-results.tap
cat ./test-results.tap | node ./node_modules/tap-teamcity/dist/index.js > ./test-results.xml

Or it can be used as a module, in which case there are a few more options available:

const tapTeamcity = require('@sa0001/tap-teamcity')

await tapTeamcity('./test-results.tap', './test-results.xml', {
	// custom top-level suite name
	suiteName: 'TAP',
	// edit the full name of the test, for example to shorten or remove the file path
	editTestName: (name) => { return name },
	// filter the lines of the error stack, to remove noise
	filterErrorStack: (line) => { return true },
})

License

MIT

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published