0.2.0 • Published 1 year ago

utap v0.2.0

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

μtap

A micro TAP formatter that works very well with the Node >=18 built-in node:test harness.

  • The output format is inspired by AVA.
  • Less than 100 lines of code, and a single chalk dependency.

Example output

Give it a try

node my.test.js | npx utap

Use it in your project

npm install --save-dev utap

Put your tests in tests/ directory (or wherever you like really)

In your package.json:

  "scripts": {
    "test": "find tests -type f -name '*.test.js' -exec echo \\# utap-src:{} \\; -exec node {} \\; | utap"
  },

Adding the # utap-src:{filename} comment in between individual test files' TAP output allows utap to report the filename together with test descriptions. Remove that part if you don't need it.

npm test

Note

I am not using the built-in node --test runner on purpose to allow for more flexibility.

0.2.0

1 year ago

0.1.3

2 years ago

0.1.2

2 years ago

0.1.1

2 years ago

0.1.0

2 years ago