https://github.com/naokikimura/junit-reports-combiner
Combine JUnit XML reports from two and more.
https://github.com/naokikimura/junit-reports-combiner
cli junit xml
Last synced: about 1 year ago
JSON representation
Combine JUnit XML reports from two and more.
- Host: GitHub
- URL: https://github.com/naokikimura/junit-reports-combiner
- Owner: naokikimura
- License: mit
- Created: 2020-02-06T07:11:15.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2023-01-05T07:56:07.000Z (over 3 years ago)
- Last Synced: 2025-03-13T16:32:35.325Z (over 1 year ago)
- Topics: cli, junit, xml
- Language: TypeScript
- Homepage: https://www.npmjs.com/package/junit-reports-combiner
- Size: 1.14 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 16
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# junit-reports-combiner
[](https://badge.fury.io/js/junit-reports-combiner) [](https://circleci.com/gh/naokikimura/junit-reports-combiner) [](https://codecov.io/gh/naokikimura/junit-reports-combiner) [](https://snyk.io/test/github/naokikimura/junit-reports-combiner?targetFile=package.json)
Combine JUnit XML reports from two and more.
The reports of two and more can be combined using the set operations union, intersection, and difference.
## Installation
### Requires
- Node.js 10+
### CLI
```sh
npm i -g junit-reports-combiner
```
### Modules
```sh
npm i junit-reports-combiner
```
## Usage
### CLI
Combines two reports:
```sh
junit-reports-combiner TEST-example.FooTest.xml TEST-example.BarTest.xml
```
See the `man junit-reports-combiner` for details.
### Modules
```javascript
import { DOMParser } from 'xmldom';
import JUnitReportsCombiner from 'junit-reports-combiner';
const parser = new DOMParser();
const xml1 = `
`;
const doc1 = parser.parseFromString(xml1, 'application/xml');
const xml2 = `
java.lang.AssertionError
`;
const doc2 = parser.parseFromString(xml2, 'application/xml');
const combiner = new JUnitReportsCombiner();
const doc3 = combiner.combine(doc1, doc2);
```
## Contributing
Bug reports and pull requests are welcome on GitHub at https://github.com/naokikimura/junit-reports-combiner
## License
The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).