tape-describe
Describe blocks for your tape tests.
tape-describe is a decorator for tape that prefixes each test name with a given description.
Please note: tape-describe does not attempt to produce nested TAP output.
Install
npm install tape-describe --save-dev
Requires tape
to be installed.
Usage
tape-describe can be used with or without a callback depending on your preference.
Both of the following examples will yield the following TAP output:
# foo: bar
ok 1 should be truthy
With callback
This approach should be familiar to those coming from spec-based testing tools.
const describe = ; ;
Without callback
This approach avoids nesting, making it trivial to remove tape-describe if you change your mind.
const describe = ;const test = ; ;