Skip to content

Commit f9d0659

Browse files
fabiencastancbentejac
authored andcommitted
Create .codecov.yml
1 parent 5dda2ac commit f9d0659

File tree

1 file changed

+68
-0
lines changed

1 file changed

+68
-0
lines changed

.codecov.yml

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
# Codecov configuration for Meshroom
2+
# This configuration prevents CI from failing due to small coverage decreases
3+
# while maintaining quality standards
4+
5+
codecov:
6+
# Require CI to pass before processing results
7+
require_ci_to_pass: yes
8+
9+
coverage:
10+
status:
11+
project:
12+
default:
13+
# Allow coverage to drop by up to 1% without failing
14+
threshold: 1%
15+
# Set a minimum target coverage (adjust based on your current ~77%)
16+
target: 75%
17+
# Only check coverage on lines that are coverable
18+
base: auto
19+
# Ignore if no coverage files are uploaded
20+
if_no_uploads: error
21+
# Don't fail if coverage file not found
22+
if_not_found: success
23+
# Fail if CI failed
24+
if_ci_failed: error
25+
# Only run on these branches
26+
branches:
27+
- develop
28+
- master
29+
- main
30+
31+
patch:
32+
default:
33+
# For new code, allow 2% threshold since new features may need refactoring
34+
threshold: 2%
35+
# New code should aim for 70% coverage (lower than overall project)
36+
target: 70%
37+
# Only run patch coverage on pull requests
38+
only_pulls: true
39+
if_no_uploads: error
40+
if_not_found: success
41+
if_ci_failed: error
42+
43+
precision: 2
44+
round: down
45+
range: "70...95"
46+
47+
# Configure the PR comment
48+
comment:
49+
layout: "reach,diff,flags,tree"
50+
behavior: default
51+
require_changes: false
52+
require_base: no
53+
require_head: yes
54+
branches:
55+
- develop
56+
- master
57+
- main
58+
59+
# Ignore certain files/directories that shouldn't affect coverage
60+
ignore:
61+
- "tests/"
62+
- "**/*_test.py"
63+
- "**/test_*.py"
64+
- "setup.py"
65+
- "meshroom/ui/**" # ignore coverage of UI components
66+
- "docs/"
67+
- "scripts/"
68+
- "bin/"

0 commit comments

Comments
 (0)