diff --git a/.travis.yml b/.travis.yml index d82859d15..a943ac2ab 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,11 +6,6 @@ before_install: # Delete .git/ to maximize ccache effectiveness (no version string mismatches) - rm -rf .git -branches: - only: - - master - - winterbreeze - jobs: include: - name: "Build with most recent GCC & Clang, run tests" diff --git a/ci-build.py b/ci-build.py index 1cd8d06d1..070e04e56 100755 --- a/ci-build.py +++ b/ci-build.py @@ -105,7 +105,13 @@ def tox(tox_args, build_dir): tox('-e flake8', build_dir) if args.run_tests: - tox('-e py37 -- -n auto --cache-clear -v -x', build_dir) + # Run completion tests separately in order to exclude them from the + # coverage analysis. (Those tests do not verify functionality but just + # the absence of unexpected crashes.) + tox('-e py37 -- -n auto --cache-clear -v -x tests/test_completion.py', build_dir) + sp.check_call('lcov --zerocounters --directory .', shell=True, cwd=build_dir) + + tox('-e py37 -- -n auto --cache-clear -v -x --ignore=tests/test_completion.py', build_dir) sp.check_call('lcov --capture --directory . --output-file coverage.info', shell=True, cwd=build_dir) sp.check_call('lcov --remove coverage.info "/usr/*" --output-file coverage.info', shell=True, cwd=build_dir) diff --git a/src/rootcommands.cpp b/src/rootcommands.cpp index 48cbf9600..d74ed45d0 100644 --- a/src/rootcommands.cpp +++ b/src/rootcommands.cpp @@ -82,6 +82,7 @@ int RootCommands::attr_cmd(Input in, Output output) { << new_value << "\" is not a valid value for " << a->name() << ": " << error_message << endl; + output << "making the coverage even worse, for the lulz"; return HERBST_INVALID_ARGUMENT; } }