소개
컴파일된 프로그램, Python, Bash를 위한 코드 커버리지 도구입니다. 디버깅 정보를 사용해 데이터를 수집하고 보고하므로 별도의 컴파일 옵션이 필요하지 않습니다.
개발 도구측정된 스타 증가
- in 24h
- 0
- in 7 days
- 0
- in 15 days
- +3
- in 1 month
- 기록 수집 중
서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.
README.md
Originalkcov
Kcov is a FreeBSD/Linux/Mac OS code coverage tester for compiled languages, Python and Bash. Kcov was originally a fork of Bcov, but has since evolved to support a large feature set in addition to that of Bcov.
Kcov, like Bcov, uses DWARF debugging information for compiled programs to make it possible to collect coverage information without special compiler switches.
For a video introduction, look at this presentation from SwedenCPP
Installing
Refer to the INSTALL file for build instructions, or use our official Docker image (kcov/kcov):
- kcov/kcov for releases since v31.
Docker images and usage is explained more in the docker page.
How to use it
Basic usage is straight-forward:
kcov /path/to/outdir executable [args for the executable]
/path/to/outdir will contain lcov-style HTML output generated continuously while the application runs. Kcov will also write cobertura- compatible XML output and generic JSON coverage information and can easily be integrated in various CI systems.
Filtering output
It's often useful to filter output, since e.g., /usr/include is seldom of interest. This can be done in two ways:
kcov --exclude-pattern=/usr/include --include-pattern=part/of/path,other/path \
/path/to/outdir executable
which will do a string-comparison and include everything which contains part/of/path or other/path but exclude everything that has the /usr/include string in it.
kcov --include-path=/my/src/path /path/to/outdir executable
kcov --exclude-path=/usr/include /path/to/outdir executable
Does the same thing, but with proper path lookups.
Merging multiple kcov runs
Kcov can also merge the results of multiple earlier runs. To use this mode,
call kcov with --merge, an output path and one or more paths to an earlier
run, e.g.,
kcov --merge /tmp/merged-output /tmp/kcov-output1 /tmp/kcov-output2
kcov --merge /tmp/merged-output /tmp/kcov-output* # With a wildcard
Integration with other systems
kcov is easy to integrate with travis-ci/GitHub actions together with coveralls.io or codecov.io. It can also be used from Jenkins, SonarQube and GitLab CI. Refer to
- vscode for details about vscode + coverage gutters
- coveralls for details about travis-ci + coveralls, or
- codecov for details about travis-ci + codecov
- jenkins for details about how to integrate in Jenkins
- sonarqube for how to use kcov and sonarqube together
- GitHub for use with GitHub
- gitlab for use with GitLab
More information
kcov is written by Simon Kagstrom [email protected] and more information can be found at the web page
관련 프로젝트 살펴보기
불러오는 중…