Currently I am working on a Node.js module to abstract cloud storage interaction with filesystem idioms. My partner in the project suggested to use Makefile for running test scripts. So I created following Makefile
1 2 3 4 5 6 7 8 9
When I run
make test I always got following response
So, what is the problem?
Apparently I have a folder named
test (which contains all of test scripts). When I run
make test, then Make command will be executed againts the
If you have same command name and file/folder name on your project and you want to execute the command in Makefile, then you have to add .PHONY to tell the compiler to execute the command Makefile. The special rule .PHONY tells Make which targets are not files.
So update the Makefile to
1 2 3 4 5 6 7 8 9 10 11
And the tests are running