mirror of
/repos/Prototyper.git
synced 2025-12-30 06:31:32 +01:00
24 lines
583 B
Bash
Executable File
24 lines
583 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
current_dir=$(cd $(dirname $0) && pwd)
|
|
base_dir=${current_dir}/..
|
|
cd ${base_dir}
|
|
|
|
if [[ ! -x ./opt/node-jscoverage/jscoverage ]]; then
|
|
mkdir -p ./opt
|
|
cd ./opt
|
|
git clone git://github.com/visionmedia/node-jscoverage.git
|
|
cd node-jscoverage/
|
|
./configure && make
|
|
cd ${base_dir}
|
|
fi
|
|
|
|
if [[ ! -x ./node_modules/.bin/mocha ]]; then
|
|
npm install mocha
|
|
fi
|
|
|
|
./opt/node-jscoverage/jscoverage lib lib-cov
|
|
PROTOTYPER_COV=1 ./node_modules/.bin/mocha -R html-cov > ./doc/coverage.html
|
|
rm -rf lib-cov
|
|
echo "coverage.html generated in doc/coverage.html"
|