Sample configuration to unit test a ReactJS application.
The unit tests run in nodejs, without any browser.
The build is based on:
- nodejs / npm
- gulp
- browserify, to write nodejs modules that can be used in the browser
- mocha, for unit tests
- cheerio to analyse the produced HTML in the tests
- jsdom, for testing DOM
npm install -D
./node_modules/.bin/gulp
./node_modules/.bin/gulp build
./node_modules/.bin/gulp test
./node_modules/.bin/gulp build --production
./node_modules/.bin/gulp clean