Ran
|
Files
6
|
Run time
0s
|
Badge
Embed ▾
README BADGES
|
push
travis-ci
test, kcov: Run coverage only by default on Travis Now, instead of having Travis run the test, then run them again, and ignore the return status of `kcov`, this change should allow Travis to just perform the coverage run and rely on the `kcov` exit status. As explained in the comment for the `test: run coverage by default on Travis Linux` test case: This test also makes sure the invocation doesn't cause a second recursive call to `run_kcov` thanks to the `_COVERAGE_RUN` variable. Previously, seemingly successful coverage runs (added in commit 4440832c2) were causing Travis failures, ameliorated in commit cc284d11e. These were due to the `run_kcov` getting called recursively and failing because the first call already created the `tests/coverage` directory. Here was the chain of events: - Travis calls `./go test`. - Test suite runs and succeeds. - `"$?" -eq '0' && "$TRAVIS_OS_NAME" == 'linux'` condition met. - `_test_coverage` and `run_kcov` executed. - `run_kcov` creates `tests/coverage` and executes `kcov ./go test`. - Test suite runs and succeeds. - `"$?" -eq '0' && "$TRAVIS_OS_NAME" == 'linux'` condition met. - `_test_coverage` and `run_kcov` executed. - `run_kcov` fails because `tests/coverage` already exists. - `kcov` sends coverage info to Coveralls, but exits with an error. - Travis build reports failure. With the `_COVERAGE_RUN` variable, the recursive call is now short-circuited.
96 of 231 relevant lines covered (41.56%)
132.04 hits per line
Coverage | ∆ | File | Lines | Relevant | Covered | Missed | Hits/Line |
---|