@tapjs/after-each
a built-in tap extension for t.afterEach()
Last updated 7 months ago by isaacs .
BlueOak-1.0.0 · Repository · Bugs · Original npm · Tarball · package.json
$ npm install @tapjs/after-each 
SYNC missed versions from official npm registry.

@tapjs/after-each

A default tap plugin providing t.afterEach().

USAGE

This plugin is installed with tap by default. If you had previously removed it, you can tap plugin add @tapjs/after-each to bring it back.

import t from 'tap'
t.afterEach(t => {
  // this will run after each child test, all of their child
  // tests, and so on
  // the parameter is the child test that just ended.
})

If the method returns a promise, it will be awaited before moving on to the next test.

The afterEach method is called for all child tests, not just direct children. "Closer" ancestor afterEach methods are called before further ancestors.

For example, this test:

import t from 'tap'
t.afterEach(t => {
  console.error('root after each', t.name)
})

t.test('parent test', t => {
  t.afterEach(t => {
    console.error('parent after each', t.name)
  })
  t.test('child test', t => t.end())
  t.end()
})

will print:

parent after each child test
root after each child test
root after each parent test

Current Tags

  • 4.3.13                                ...           latest (24 days ago)
  • 1.0.0                                ...           pre (3 years ago)

92 Versions

  • 4.3.13                                ...           24 days ago
  • 4.3.12                                ...           3 months ago
  • 4.3.11                                ...           4 months ago
  • 4.3.10                                ...           6 months ago
  • 4.3.9                                ...           6 months ago
  • 4.3.8                                ...           7 months ago
  • 4.3.7                                ...           7 months ago
  • 4.3.6                                ...           7 months ago
  • 4.3.5                                ...           8 months ago
  • 4.3.4                                ...           9 months ago
  • 4.3.3                                ...           9 months ago
  • 4.3.2                                ...           9 months ago
  • 4.3.1                                ...           10 months ago
  • 4.3.0                                ...           a year ago
  • 4.2.1                                ...           a year ago
  • 4.2.0                                ...           a year ago
  • 4.1.0                                ...           a year ago
  • 4.0.7                                ...           a year ago
  • 4.0.6                                ...           a year ago
  • 4.0.5                                ...           a year ago
  • 4.0.4                                ...           a year ago
  • 4.0.3                                ...           a year ago
  • 4.0.2                                ...           a year ago
  • 4.0.1                                ...           2 years ago
  • 4.0.0                                ...           2 years ago
  • 3.0.3                                ...           2 years ago
  • 3.0.2                                ...           2 years ago
  • 3.0.1                                ...           2 years ago
  • 3.0.0                                ...           2 years ago
  • 2.0.8                                ...           2 years ago
  • 2.0.7                                ...           2 years ago
  • 2.0.6                                ...           2 years ago
  • 2.0.5                                ...           2 years ago
  • 2.0.4                                ...           2 years ago
  • 2.0.3                                ...           2 years ago
  • 2.0.2                                ...           2 years ago
  • 2.0.1                                ...           3 years ago
  • 2.0.0                                ...           3 years ago
  • 1.1.22                                ...           3 years ago
  • 1.1.21                                ...           3 years ago
  • 1.1.20                                ...           3 years ago
  • 1.1.19                                ...           3 years ago
  • 1.1.18                                ...           3 years ago
  • 1.1.17                                ...           3 years ago
  • 1.1.16                                ...           3 years ago
  • 1.1.15                                ...           3 years ago
  • 1.1.14                                ...           3 years ago
  • 1.1.13                                ...           3 years ago
  • 1.1.12                                ...           3 years ago
  • 1.1.11                                ...           3 years ago
  • 1.1.10                                ...           3 years ago
  • 1.1.9                                ...           3 years ago
  • 1.1.8                                ...           3 years ago
  • 1.1.7                                ...           3 years ago
  • 1.1.6                                ...           3 years ago
  • 1.1.5                                ...           3 years ago
  • 1.1.4                                ...           3 years ago
  • 1.1.3                                ...           3 years ago
  • 1.1.2                                ...           3 years ago
  • 1.1.1                                ...           3 years ago
  • 1.1.0                                ...           3 years ago
  • 1.0.7                                ...           3 years ago
  • 1.0.6                                ...           3 years ago
  • 1.0.5                                ...           3 years ago
  • 1.0.4                                ...           3 years ago
  • 1.0.3                                ...           3 years ago
  • 1.0.2                                ...           3 years ago
  • 1.0.1                                ...           3 years ago
  • 1.0.0                                ...           3 years ago
  • 0.0.0-22                                ...           3 years ago
  • 0.0.0-21                                ...           3 years ago
  • 0.0.0-20                                ...           3 years ago
  • 0.0.0-19                                ...           3 years ago
  • 0.0.0-18                                ...           3 years ago
  • 0.0.0-17                                ...           3 years ago
  • 0.0.0-16                                ...           3 years ago
  • 0.0.0-15                                ...           3 years ago
  • 0.0.0-14                                ...           3 years ago
  • 0.0.0-13                                ...           3 years ago
  • 0.0.0-12                                ...           3 years ago
  • 0.0.0-11                                ...           3 years ago
  • 0.0.0-10                                ...           3 years ago
  • 0.0.0-9                                ...           3 years ago
  • 0.0.0-8                                ...           3 years ago
  • 0.0.0-7                                ...           3 years ago
  • 0.0.0-6                                ...           3 years ago
  • 0.0.0-5                                ...           3 years ago
  • 0.0.0-4                                ...           3 years ago
  • 0.0.0-3                                ...           3 years ago
  • 0.0.0-2                                ...           3 years ago
  • 0.0.0-1                                ...           3 years ago
  • 0.0.0-0                                ...           3 years ago
Maintainers (2)
Downloads
Total 331
Today 0
This Week 0
This Month 289
Last Day 0
Last Week 99
Last Month 40
Dependencies (1)
Dev Dependencies (0)
None
Dependents (2)

© 2010 - cnpmjs.org x YWFE | Home | YWFE