diff options
| author | spreis <[email protected]> | 2025-06-12 00:11:52 +0300 |
|---|---|---|
| committer | spreis <[email protected]> | 2025-06-12 00:34:04 +0300 |
| commit | 8c07c970d1c731ca1ecb6282ed31b200765846d3 (patch) | |
| tree | 2e90feaec9ac32a4637bca34440c4894a4890ee7 /build/plugins/coverage.py | |
| parent | 3575c304717964c7bd650dedfa74c8da773e5af4 (diff) | |
Improve coverage filtering and introduce programs filtering - take2 (fixed and improved)
commit_hash:224018edeb9834af23baa6d82f6ea52f6928cd19
Diffstat (limited to 'build/plugins/coverage.py')
| -rw-r--r-- | build/plugins/coverage.py | 26 |
1 files changed, 1 insertions, 25 deletions
diff --git a/build/plugins/coverage.py b/build/plugins/coverage.py index 64e3bda9123..0ff3bff5f8e 100644 --- a/build/plugins/coverage.py +++ b/build/plugins/coverage.py @@ -1,7 +1,6 @@ import re import _common -import lib.test_const as consts def get_coverage_filter_regexp(pattern, cache={}): @@ -36,32 +35,9 @@ def get_cpp_coverage_filters(unit, filters=[]): return filters -def add_cpp_coverage_ldflags(unit): - ldflags = unit.get("LDFLAGS") - changed = False - for flag in consts.COVERAGE_LDFLAGS: - if flag not in ldflags: - ldflags = ldflags + ' ' + flag - changed = True - if changed: - unit.set(["LDFLAGS", ldflags]) - - -def add_cpp_coverage_cflags(unit): - cflags = unit.get("CFLAGS") - changed = False - for flag in consts.COVERAGE_CFLAGS: - if flag not in cflags: - cflags = cflags + ' ' + flag - changed = True - if changed: - unit.set(["CFLAGS", cflags]) - - def onset_cpp_coverage_flags(unit): if unit.get("CLANG_COVERAGE") == "no": return filters = get_cpp_coverage_filters(unit) if should_be_covered(unit, filters): - add_cpp_coverage_cflags(unit) - add_cpp_coverage_ldflags(unit) + unit.on_setup_clang_coverage() |
