Skip to content

tapjs/tapjs

Repository files navigation

@tapjs

Workspace for node-tap development.

Dev Commands

Do this at least once to get everything set up and ready to go:

npm run bootstrap

(Note:npm installwill not workuntil you do this, because the generated TypeScript eats its own tail.)


Build the test class (required after any plugin or core changes):

npm run build

Any other builds:

npm run prepare -w src/{whatever}

After adding or removing workspaces:

npm i

Run all tests in all workspaces:

npm test

Run all tests, saving snapshots:

npm run snap

Build and serve docs:

npm start

Contents

  • tapThe main entry point module, which sets up the root test runner and exposes an alias to the cli runner.
  • tap-parser The module that parsesTAP
  • @tapjs/core Most of the basic moving parts of tap
  • tap-yaml Thin wrapper aroundYAMLand yaml-typesfor consistent handling of JavaScript values in YAML diagnostics.
  • @tapjs/test The plugin-ifiedTestclass.
  • @tapjs/config Handling config files, command line interface parsing, environment variables, and validation
  • @tapjs/run The command line runner
  • tcompare The library that does comparison and object formatting (use heavily by@tapjs/assertsmethods).
  • @tapjs/stack Library for capturing stack frames, the descendant of stack-utils.
  • @tapjs/processinfo The library that tracks process information and code coverage (hosted outside the monorepo, because it can't be tested by a version of tap that uses itself without bootstrap paradoxes)
  • default plugins:
  • optional plugins:
  • other stuff:
    • npm-init-template A library for more easily creatingnpm initpackages. This will move out as soon as this version of tap is published.
    • @tapjs/create-plugin Annpm initlibrary facilitatingnpm init @tapjs/plugin to create new plugins.

Bootstrap andskipLibCheck

Runnpm run bootstrapto build the@tapjs/testmodule with the default set of plugins, so that the other libraries can build properly. (This only has to be done once, unless the build script or set of default plugins are changed, of course.)

Because there's a bootstrapping cycle between@tapjs/core, @tapjs/test,and all of the plugins, they MUST use skipLibCheck: truein their tsconfigs. It should not be used in other packages.