This repository has been archived by the owner on Dec 21, 2023. It is now read-only.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
We were using coveralls. The best client for C++ seems to be cpp-coveralls, which:
does not work with Python 3.3, which is what we have in Ubuntu 18.04
does not work with Debian testing even though this issue has been fixed in master
even when using the master branch in Debian testing, it shows other issues that I could not easily understand or fix
At the same time, using an older distribution image is problematic because the code in here is assuming that we use OpenSSL 1.1.0+.
I spent a fair amount of time trying to fix this issue in several ways, then I decided to give up and use a much better strategy:
measure the coverage using
lcov
which is more likely to be up-to-date withgcc
format thancpp-coveralls
since it's developed by the GNU projectuse codecov that allows to submit a
.lcov
filealso, use codecov because their client is written in
bash
, hence it does not suffer of all the issues that plague Python dependency management (long live, Go static binaries!).As a note for the future self, it was also theoretically possible to avoid the
lcov
step, except that there is more than a single test binary, hence there are multiple coverage measurements. The default behaviour ofcodecov.bassh
is such that it only takes one of these measurements, hence reporting a wrong coverage measurement (here's a place where cpp-coveralls is clearly doing better than codecov). This issue has been discussed, e.g., in JoakimSoderberg/coveralls-cmake#17. My solution to this problem is to letlcov
(which should be in sync withgcc
) do the dirty work of merging the various coverage reports and produce a consistent summary.