@onerepo/plugin-jest
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

Jest is the recomended framework for headless testing with oneRepo. As opposed to Vitest and others, Jest allows a single runner that can use multiple project configurations. Think of each project as a separate workspace in your repo.

The added benefit of Jest is that as you are working, you can run this single command and it will automatically test appropriate files related to your changes across all workspaces. There's no need to determine which workspaces to run – and can all be done with --watch mode at the same time.

Installation

npm install --save-dev @onerepo/plugin-jest

Create a root level jest config with the appropriate references to your workspace Jest configs:

/** @type {import('jest').Config} */
export default {
	projects: ['<rootDir>/apps/*/jest.config.js', '<rootDir>/modules/*/jest.config.js'],
};

Readme

Keywords

none

Package Sidebar

Install

npm i @onerepo/plugin-jest

Weekly Downloads

45

Version

1.0.0

License

MIT

Unpacked Size

113 kB

Total Files

8

Last publish

Collaborators

  • paularmstrong