Mocha Adapter for JsTestDriver
- Jan Prachař (jan@prachar.eu)
- JsTestDriver (JSTD)
- Mocha (browser version – mocha.js)
- Any assertion library (e.g. Chai: browser version – chai.js)
Update your jsTestDriver.conf
file (see wiki page for more info) by prepending the Mocha and assertion library and the adapter's source files.
For example:
load:
- "lib/mocha.js"
- "lib/chai.js"
- "lib/MochaAdapter.js"
- "your_source_files.js"
test:
- "your_test_files.js"
Then you must setup Mocha and assertion library like for use in the browser, i.e. tell Mocha which interface you wish to use. A typical setup might look like the following.
mocha.setup('bdd');
expect = chai.expect;
- src: The adapter source code. Intent is to match interface with interface.
- src-test: The test files that verifies that the adapter works as intended.
- 1.0.0 – 2013-03-25 – Initial release