Skip to content

Commit

Permalink
feat: Force NODE_ENV to "test" when run it
Browse files Browse the repository at this point in the history
If your application uses cozy-scripts to run tests,
you can remove `env NODE_ENV=test` from your script
  • Loading branch information
Merkur39 committed Jan 15, 2024
1 parent f6768e0 commit 70a9f29
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions packages/cozy-scripts/scripts/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
const jestAPI = require('jest')

function runJest(options) {
if (!process.env.NODE_ENV) process.env.NODE_ENV = 'test'
const { cliArgs } = options

jestAPI.run(cliArgs)
Expand Down

0 comments on commit 70a9f29

Please sign in to comment.