I am trying to create a MakeFile to run my Mocha unit tests with NPM. So I have Mocha installed and a unit test created in:
{project_root}/test/test.js
Now, when I try 'make test' Make replies with:
make: Nothing to be done for `test'.
Here's my MakeFile:
test:
@./node_modules/.bin/mocha -u tdd
.PHONY: test
So real basic. I've read that Mocha will run all tests in the 'test' dir automatically. Is my MakeFile syntax incorrect?
Thanks!
make -f MakeFile test. Also i would put the .Phony line before the test target and check my makefile with the command cat -e -t -v MakeFile --> it shows tabs as ^I and line endings as $ . let me know if it still dosent work - AppleBee12makefileorMakefile. The uppercase F inmakeFile/MakeFileis what trips this error. Case matters! - Adam Terlson