$ vim package.json { "name": "coveragesample", "version": "0.0.1", "private": true, "dependencies": { "coffee-script": "1.7.1", "chai": "1.9.1", "mocha": "1.20.1", "blanket": "1.1.6" } } $ npm install
Test codemodule.exports = -> true
Setting of Mochamain = require('../src/'); assert = require('chai').assert describe 'testing', -> it 'is pretty nice with CoffeeScript', -> assert main() == true
Run test--compilers coffee:coffee-script/register --reporter spec
$./node_modules/.bin/mocha testing ✓ is pretty nice with CoffeeScript 1 passing (8ms)
Add option to mocha.opts{ "name": "coveragesample", "version": "0.0.1", "private": true, "dependencies": { "coffee-script": "1.7.1", "chai": "1.9.1", "mocha": "1.20.1", "blanket": "1.1.6" }, "config": { "blanket": { "pattern": "src", "loader": "./node-loaders/coffee-script", "data-cover-never": "node_modules" } } }
Run coverage measuring--compilers coffee:coffee-script/register --reporter spec --require blanket
$ ./node_modules/.bin/mocha -R html-cov test > coverage.html
Streamlit is a …
I bought M5Stac…