Skip to content

Commit

Permalink
Report test failures in CI
Browse files Browse the repository at this point in the history
Due to occasional unavailability in the code coverage reporting service,
the continuous integration environment does not reject builds that
experience issues with this task.

This behavior was previously implemented in such a way to allow errors
of *any* kind--including test failures. Re-implement to limit the scope
of "allowed errors," to the reporting command only.
  • Loading branch information
jugglinmike authored and fb55 committed Feb 12, 2017
1 parent 692e301 commit 6b921df
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions Makefile
Expand Up @@ -16,11 +16,14 @@ subl:
test-cov:
@./node_modules/.bin/istanbul cover node_modules/.bin/_mocha -- --recursive --reporter $(REPORTER)

# Due to occasional unavailability of the code coverage reporting service, the
# exit status of the command in this recipe may optionally be ignored.
report-cov: test-cov
@cat coverage/lcov.info | ./node_modules/.bin/coveralls
@cat coverage/lcov.info | ./node_modules/.bin/coveralls || [ "$(OPTIONAL)" = "true" ]

travis-test: lint
@make report-cov || echo "Couldn't submit"
travis-test: OPTIONAL = true
travis-test: lint report-cov
@true

bench:
@./benchmark/benchmark.js
Expand Down

0 comments on commit 6b921df

Please sign in to comment.