Node.js v20.14.0 documentation
- Node.js v20.14.0
-
Table of contents
- Test runner
- Subtests
- Skipping tests
- TODO tests
describe()andit()aliasesonlytests- Filtering tests by name
- Extraneous asynchronous activity
- Watch mode
- Running tests from the command line
- Collecting code coverage
- Mocking
- Test reporters
run([options])suite([name][, options][, fn])suite.skip([name][, options][, fn])suite.todo([name][, options][, fn])suite.only([name][, options][, fn])test([name][, options][, fn])test.skip([name][, options][, fn])test.todo([name][, options][, fn])test.only([name][, options][, fn])describe([name][, options][, fn])describe.skip([name][, options][, fn])describe.todo([name][, options][, fn])describe.only([name][, options][, fn])it([name][, options][, fn])it.skip([name][, options][, fn])it.todo([name][, options][, fn])it.only([name][, options][, fn])before([fn][, options])after([fn][, options])beforeEach([fn][, options])afterEach([fn][, options])- Class:
MockFunctionContext - Class:
MockTracker - Class:
MockTimers - Class:
TestsStream - Class:
TestContext
- Test runner