File README.md changed (mode: 100644) (index 0dcfd10..a663d1a) |
1 |
1 |
**uncov**, _v0.3_, _2016 – 2021_ |
**uncov**, _v0.3_, _2016 – 2021_ |
2 |
2 |
|
|
3 |
|
_This file last updated on 26 May, 2021_ |
|
|
3 |
|
_This file last updated on 6 June, 2021_ |
4 |
4 |
|
|
5 |
5 |
1. [Description](#description) |
1. [Description](#description) |
6 |
6 |
2. [Supported Environment](#supported-environment) |
2. [Supported Environment](#supported-environment) |
|
... |
... |
Expected to work in Unix-like environments. |
80 |
80 |
|
|
81 |
81 |
## Usage ## |
## Usage ## |
82 |
82 |
|
|
83 |
|
GCC 8 and newer (json format of intermediate data isn't handled by `new-gcovi`): |
|
|
83 |
|
Using subcommand (should be faster and less problematic): |
|
84 |
|
|
|
85 |
|
# drop coverage counters from previous run |
|
86 |
|
find . -name '*.gcda' -delete |
|
87 |
|
# << run tests here >> |
|
88 |
|
# collect coverage (--capture-worktree automatically makes stray commit if |
|
89 |
|
# worktree is dirty) |
|
90 |
|
uncov new-gcovi --exclude tests/ --exclude web/ --capture-worktree |
|
91 |
|
|
|
92 |
|
Using a Python script: |
84 |
93 |
|
|
85 |
94 |
# reset coverage counters from previous runs |
# reset coverage counters from previous runs |
86 |
95 |
find . -name '*.gcda' -delete |
find . -name '*.gcda' -delete |
87 |
|
# < run tests here > |
|
|
96 |
|
# << run tests here >> |
88 |
97 |
# generage coverage for every object file found (change "." to build root) |
# generage coverage for every object file found (change "." to build root) |
89 |
98 |
find . -name '*.o' -exec gcov -p {} + |
find . -name '*.o' -exec gcov -p {} + |
90 |
|
# generage and combine coverage reports (--capture-worktree automatically |
|
91 |
|
# makes stray commit if worktree is dirty) |
|
|
99 |
|
# collect coverage (--capture-worktree automatically makes stray commit if |
|
100 |
|
# worktree is dirty) |
92 |
101 |
uncov-gcov --root . --no-gcov --capture-worktree --exclude tests | uncov new |
uncov-gcov --root . --no-gcov --capture-worktree --exclude tests | uncov new |
93 |
102 |
# remove coverage reports |
# remove coverage reports |
94 |
103 |
find . -name '*.gcov' -delete |
find . -name '*.gcov' -delete |
95 |
104 |
|
|
96 |
|
Earlier versions of GCC: |
|
97 |
|
|
|
98 |
|
# drop coverage counters from previous run |
|
99 |
|
find . -name '*.gcda' -delete |
|
100 |
|
# < run tests at this point > |
|
101 |
|
uncov new-gcovi --exclude tests/ --exclude web/ --capture-worktree |
|
102 |
|
|
|
103 |
105 |
### Example ### |
### Example ### |
104 |
106 |
|
|
105 |
107 |
The easiest way of checking out `uncov` is by using it on itself (assuming that |
The easiest way of checking out `uncov` is by using it on itself (assuming that |
File docs/uncov-gcov.1 changed (mode: 100644) (index 3328e4e..e01eeb2) |
1 |
1 |
.\" Automatically generated by Pandoc 1.17.0.3 |
.\" Automatically generated by Pandoc 1.17.0.3 |
2 |
2 |
.\" |
.\" |
3 |
|
.TH "uncov-gcov" "1" "June 05, 2021" "uncov v0.3" "" |
|
|
3 |
|
.TH "uncov-gcov" "1" "June 06, 2021" "uncov v0.3" "" |
4 |
4 |
.hy |
.hy |
5 |
5 |
.SH NAME |
.SH NAME |
6 |
6 |
.PP |
.PP |
7 |
7 |
uncov\-gcov is coverage information collector for C and C++ languages |
uncov\-gcov is coverage information collector for C and C++ languages |
8 |
8 |
that can be used with \f[B]uncov(1)\f[]. |
that can be used with \f[B]uncov(1)\f[]. |
|
9 |
|
.PP |
|
10 |
|
\f[B]NOTE:\f[] since uncov\-gcov isn\[aq]t the only way to collect C and |
|
11 |
|
C++ coverage for uncov anymore, its use is discouraged. |
|
12 |
|
It is provided in case it might work better in some contexts because of |
|
13 |
|
some unique options (like taking exclusion markers of LCOV into |
|
14 |
|
account). |
|
15 |
|
It might be a good idea to switch to using "uncov new\-gcovi" |
|
16 |
|
subcommand. |
9 |
17 |
.SH SYNOPSIS |
.SH SYNOPSIS |
10 |
18 |
.PP |
.PP |
11 |
19 |
\f[B]uncov\-gcov\f[] \f[B]\-h|\-\-help\f[] |
\f[B]uncov\-gcov\f[] \f[B]\-h|\-\-help\f[] |
File docs/uncov-gcov/01-name.md changed (mode: 100644) (index 0cd7ebb..182965b) |
... |
... |
NAME |
3 |
3 |
|
|
4 |
4 |
uncov-gcov is coverage information collector for C and C++ languages that can be |
uncov-gcov is coverage information collector for C and C++ languages that can be |
5 |
5 |
used with **uncov(1)**. |
used with **uncov(1)**. |
|
6 |
|
|
|
7 |
|
**NOTE:** since uncov-gcov isn't the only way to collect C and C++ coverage for |
|
8 |
|
uncov anymore, its use is discouraged. It is provided in case it might work |
|
9 |
|
better in some contexts because of some unique options (like taking exclusion |
|
10 |
|
markers of LCOV into account). It might be a good idea to switch to using |
|
11 |
|
"uncov new-gcovi" subcommand. |