Hi! We are really excited that you are interested in contributing to vitest
. Before submitting your contribution, please make sure to take a moment and read through the following guide:
The vitest
repo is a monorepo using pnpm
workspaces. The package manager used to install and link dependencies must be pnpm.
To develop and test vitest
package:
-
Run
pnpm i
invitest
's root folder -
Run
pnpm run dev
to build sources in watch mode -
Run
pnpm run test
to run core testspnpm run test:all
to run all the suite
If you want to use break point and explore code execution you can use the "Run and debug" feature from vscode.
-
Add a
debugger
statement where you want to stop the code execution. -
Click on the "Run and Debug" icon in the activity bar of the editor.
-
Click on the "Javascript Debug Terminal" button.
-
It will open a terminal, then type the test command:
pnpm run test
-
The execution will stop and you'll use the Debug toolbar to continue, step over, restart the process...