]> git.codecow.com Git - Monocypher.git/commitdiff
Fixed code coverage checking
authorLoup Vaillant <loup@loup-vaillant.fr>
Sun, 1 Oct 2017 14:05:41 +0000 (16:05 +0200)
committerLoup Vaillant <loup@loup-vaillant.fr>
Sun, 1 Oct 2017 14:05:41 +0000 (16:05 +0200)
Fixed #47

The manual was missing the `-fcoverage-mapping` option, of course we
didn't have coverage data...

Also changed `llvm-cov` to `llvm-cov-3.8` on tests/coverage.sh: some
systems don't have the versionless alias.

README.md
tests/coverage.sh

index fddc82fcbb8cafe03f384cab1165e631ce3f5843..d8655fa827e55594a12ef333fe765a1e02afb5e2 100644 (file)
--- a/README.md
+++ b/README.md
@@ -88,7 +88,7 @@ You can run the test suite under clang sanitizers or valgrind:
 You can also check code coverage:
 
     $ make clean
-    $ make test CC="clang -std=c99" CFLAGS="-fprofile-instr-generate"
+    $ make test CC="clang -std=c99" CFLAGS="-fprofile-instr-generate -fcoverage-mapping"
     $ tests/coverage.sh
 
 
index a802025c556e00fcfc58942c16c3e8d06e345aa9..9bf5bc9e2845287843a008b57876e1a13f72e266 100755 (executable)
@@ -1,4 +1,4 @@
 #! /bin/sh
 
 llvm-profdata-3.8 merge default.profraw -o all.profdata
-llvm-cov show "./test.out" -instr-profile=all.profdata
+llvm-cov-3.8 show -instr-profile=all.profdata "./test.out"