Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/anko/tap-merge
library and CLI tool that merges multiple Test Anything Protocol streams
https://github.com/anko/tap-merge
merge stream tap
Last synced: 4 days ago
JSON representation
library and CLI tool that merges multiple Test Anything Protocol streams
- Host: GitHub
- URL: https://github.com/anko/tap-merge
- Owner: anko
- License: isc
- Created: 2015-05-31T23:52:15.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2019-11-21T18:28:50.000Z (about 5 years ago)
- Last Synced: 2024-04-25T19:02:21.079Z (8 months ago)
- Topics: merge, stream, tap
- Language: LiveScript
- Homepage:
- Size: 17.6 KB
- Stars: 13
- Watchers: 3
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: readme.markdown
- License: LICENSE
Awesome Lists containing this project
- awesome-tap - tap-merge - Merge multiple TAP streams. (Tools / JavaScript)
README
# tap-merge [![Travis CI status](https://img.shields.io/travis/anko/tap-merge.svg?style=flat-square)][1] [![npm package version](https://img.shields.io/npm/v/tap-merge.svg?style=flat-square)][2]
Merge [TAP 13][3] streams.
Re-numbers tests and test plans to remove conflicts. The test plan (e.g.
`1..5`) line is emitted last. Can be used from the command line or as a
module. Streams everything, so it can process concurrently with the TAP
producers.Only asserts, plans and the version header lines are parsed. Everything else
is left alone, so extras like YAML blocks or subtests will work.## CLI usage
cat <(tapProducer1) <(tapProducer2) | tap-merge
or otherwise concatenate two TAP streams and feed them on `stdin` to
`tap-merge`.## Module usage
```js
var tapMerge = require("tap-merge");
process.stdin // or any readable stream
.pipe(tapMerge())
.pipe(process.stdout); // or any writable stream
```If you want to give it multiple streams one after the other, use a module like
[multistream][4].## Example
Input (two TAP streams, one after the other):
TAP version 13
1..3
# first test
ok 1 - yep
# second test
ok 2 - yep
# third test
ok 3 - yepTAP version 13
1..2
not ok 1 - fail
ok 2 - just fineOutput (one TAP stream; conflicts resolved):
TAP version 13
# first test
ok 1 - yep
# second test
ok 2 - yep
# third test
ok 3 - yepnot ok 4 - fail
ok 5 - just fine
1..5## Limitations
Doesn't do validation. Provide valid input.
## License
[ISC][5].
[1]: https://travis-ci.org/anko/tap-merge
[2]: https://www.npmjs.com/package/tap-merge
[3]: https://testanything.org/tap-version-13-specification.html
[4]: https://www.npmjs.com/package/multistream
[5]: http://en.wikipedia.org/wiki/ISC_license