aboutsummaryrefslogtreecommitdiffstats
path: root/.circleci
diff options
context:
space:
mode:
authorAnton Yuzhaninov <citrin+git@citrin.ru>2018-10-20 04:15:40 -0400
committerVsevolod Stakhov <vsevolod@highsecure.ru>2018-10-20 09:15:40 +0100
commit97a9de385402020d3add12517c7bccae93af593b (patch)
treeff53c36cd794f85f2159cbea19ed3bd7a1466583 /.circleci
parent97662a53f4dce272df30dac9b6aa4fc4013b0fc4 (diff)
downloadrspamd-97a9de385402020d3add12517c7bccae93af593b.tar.gz
rspamd-97a9de385402020d3add12517c7bccae93af593b.zip
Fix coverage (#2603)
* Add utility to prepare C coverage for upload to coveralls.io It turned out that it is more easy to write own script then debug and fix coveralls utility (https://github.com/eddyxu/cpp-coveralls). gcov-coveralls.py can be used as a replacement for coveralls. * Save coverage data from .gcda files only once Coverage data in .gcda files is merged after each binary invocation, so we can run all test and then gather coverage data. If we dump them two times execution counts will be more then they be. * Switch from coveralls (cpp-coveralls) to own script Problem with coveralls was, that coverage for source files outside build directory was not added to the report. * Add tool to dump info from json for coveralls.io * Add debug * Fix: don't die if there is no service_job_id in json * Debug * Fix dump_coveralls.py * Rename to gcov_coveralls.py (s/-/_/) For most files in this repo '_' is used as separator. * Don't add source code to coveralls JSON According to https://docs.coveralls.io/api-introduction Coverals don't need source code, only MD5 digest to tracks changes. Anyway source code is already added by luacov-coveralls and source_digest is added by cpp-coveralls and gcov_coveralls.py Both options seems to work for now. * Provide path to source directory to merge_coveralls.py merge_coveralls.py has code to filter files and remove prefixes. When --root points to source directory merge_coveralls.py can strip prefix from absolute path in JSONs generated by luacov-coveralls. * Style Don't add parameters with default values. * Make --output optional It useful mainly for debugging. We can send report without saving it. * Log CI_COMMIT_AUTHOR env var It is not clear from drone.io source how CI_COMMIT_AUTHOR variable is set. Log it to see what it means. * Move merge_coveralls.py to test/tools This script is used not only for funcional test coverage, but for rspamd-test coverage too. * Remove debug * Style Use more compact formatting. * Write comment about parallel tests running [SKIP CI] Document why running tests in parallel may be bad idea (but still do so). * Fix typo [SKIP CI]
Diffstat (limited to '.circleci')
-rw-r--r--.circleci/config.yml2
1 files changed, 1 insertions, 1 deletions
diff --git a/.circleci/config.yml b/.circleci/config.yml
index 83316945a..fd47c110b 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -34,7 +34,7 @@ references:
# Merge Lua coverage (collected into lua_coverage_report.json) and with C-coverage
# (in coverage.rspamd-test.dump, coverage.functional.dump, see &capture_coverage_data)
# and finally upload it into coveralls.io
- test/functional/util/merge_coveralls.py --input coverage.functional.dump coverage.rspamd-test.dump lua_coverage_report.json unit_test_lua.json --output out.josn --token=${COVERALLS_REPO_TOKEN}
+ test/tools/merge_coveralls.py --input coverage.functional.dump coverage.rspamd-test.dump lua_coverage_report.json unit_test_lua.json --output out.josn --token=${COVERALLS_REPO_TOKEN}
fi
fi