Skip to content

Commit

Permalink
Revert "Remove all code coverage measurement"
Browse files Browse the repository at this point in the history
This reverts commit be6353a.
  • Loading branch information
Lucas Wojciechowski committed Jun 2, 2016
1 parent be6353a commit 5e4465a
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,14 @@ set -o pipefail
# add npm packages to $PATH
export PATH=$(pwd)/node_modules/.bin:$PATH

# set up code coverage instrumentation
rm -rf coverage .nyc_output

# run linters
npm run lint

# run unit tests
tap --reporter dot test/js/*/*.js
tap --reporter dot --coverage --no-coverage-report test/js/*/*.js

# allow writing core files for render tests
ulimit -c unlimited -S
Expand All @@ -19,7 +22,8 @@ echo '/proc/sys/kernel/core_pattern: '`cat /proc/sys/kernel/core_pattern`
sysctl kernel.core_pattern

# run render tests
node test/render.test.js && node test/query.test.js
istanbul cover --dir .nyc_output --include-pid --report none --print none test/render.test.js &&
istanbul cover --dir .nyc_output --include-pid --report none --print none test/query.test.js
EXIT_CODE=$?

# collect core dumps from render tests
Expand All @@ -31,6 +35,10 @@ for DUMP in $(find ./ -maxdepth 1 -name 'core*' -print); do
rm -rf ${DUMP}
done

# send coverage report to coveralls
nyc report --reporter=lcov
node ./node_modules/coveralls/bin/coveralls.js < ./coverage/lcov.info

# return original error code
if [[ ${EXIT_CODE} != 0 ]]; then
exit $EXIT_CODE
Expand Down

0 comments on commit 5e4465a

Please sign in to comment.