I am trying to run test cases using mocha framework. I am trying to run it through nodemon
, but getting an error.
I have installed nodemon
already through npm install nodemon
and similarly with mocha
.
How do I run my project through nodemon
so that my test cases show the result using mocha framework?
In the Command Prompt, my test cases are not running for whatever I do with nodemon
.
Lets assume you have an entry like following in your package.json -
scripts": {
"start:test": "mocha test/ --recursive --exit"
}
To run the mocha test using nodemon please use the following command: nodemon --exec "npm run start:test"