I am using create-react-app to create a react application. When I executes npm test -- --coverage the test never exists. npm test actually runs react-scripts test. Any Idea?
-- --coverage
part won't work, and should use one of the commands below to set CI
to true
.
By default npm test runs the watcher with interactive CLI. However, you can force it to run tests once and finish the process by setting an environment variable called CI.
set CI=true && npm test
set CI=true && npm run build
($env:CI = "true") -and (npm test)
($env:CI = "true") -and (npm run build)
CI=true npm test
CI=true npm run build
NOT included in the docs
docker run -e CI=true [myImage] npm run test