Skip to main content

Jest

Set up workflow to run tests with Jest for every Pull Request.

Lern more about Jest: jestjs.io

Usage

npx setup-ci --preset --jest

Detailed behavior

Below you can find detailed information about what the script does with your project when generating Jest workflow.

Installed dependencies

  • jest (dev)

Modified and created files

FileChanges
.github/workflows/jest.ymlContains the CI workflow
package.json
  • Missing dependencies are added
  • New script: test: jest --passWithNoTests
jest.config.jsonCreated if no existing Jest configuration was detected.

Workflow details

The following diagram represents the flow of the Jest CI workflow:

Known issues and limitations

  • The jest.config.json configuration file generated by SCI might not be well tailored to your project. You will have to adjust it manually if needed.