Skip to content

👯 The most human-friendly TAP reporter - with JSON diff support

License

Notifications You must be signed in to change notification settings

openaddresses/tap-diff

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

tap-diff

npm version

The most human-friendly TAP reporter.

Screenshot

Screenshot

How to use

You can use tap-diff in the same way as other TAP reporters.

npm install -g @openaddresses/tap-diff
tape ./*.test.js | tap-diff

tap-diff uses chalk for adding color, which automatically detects color terminals. If you're piping the output and want to force color:

FORCE_COLOR=t tape ./*.test.js | tap-diff

Or use with createStream():

'use strict'

const test = require('tape')
const tapDiff = require('@openaddresses/tap-diff')

test.createStream()
  .pipe(tapDiff())
  .pipe(process.stdout)

test('timing test', (t) => {
  t.plan(2)
  t.equal(typeof Date.now, 'function')
  var start = Date.now()

  setTimeout(() => {
    t.equal(Date.now() - start, 100)
  }, 100)
})

License

MIT

About

👯 The most human-friendly TAP reporter - with JSON diff support

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%