-
Notifications
You must be signed in to change notification settings - Fork 0
Tests
Luis Eduardo Brito edited this page Sep 4, 2013
·
3 revisions
The unit-testing is enabled by the external module nodeunit, a development dependency of the project.
To run all the tests in Unix based consoles, first install nodeunit in the console profile:
npm install -g nodeunit
then run the following command:
npm test
To debug the tests in Unix based consoles, first install node-inspector:
npm install -g node-inspector
then run the following command:
npm run-script test
The commands specified above will fail in windows because they rely on a feature that is not implemented in the window cmd, passing all files from a firectory using only path/*
. Because of this, the only workaround is running the tests one by one. Solutions are welcome! :)
To run a single test:
nodeunit /path/to/file.js
To debug a single test, you need to install nodeunit in your system:
npm install -g nodeunit
and then:
node --debug-brk `which nodeunit``` /path/to/file.js