Skip to content

Commit 40d6063

Browse files
authored
ci(feat): Onboard codecov (#173)
* ci(feat): Onboard codecov Signed-off-by: oliver könig <[email protected]> * f Signed-off-by: oliver könig <[email protected]> * f Signed-off-by: oliver könig <[email protected]> * f Signed-off-by: oliver könig <[email protected]> * f Signed-off-by: oliver könig <[email protected]> * f Signed-off-by: oliver könig <[email protected]> * f Signed-off-by: oliver könig <[email protected]> --------- Signed-off-by: oliver könig <[email protected]>
1 parent a183738 commit 40d6063

File tree

3 files changed

+34
-6
lines changed

3 files changed

+34
-6
lines changed

.coveragerc

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
[paths]
2+
source =
3+
nemo_run/
4+
/home/runner/work/NeMo-Run/NeMo-Run/nemo_run
5+
/opt/NeMo-Run/nemo_run
6+
[run]
7+
omit =
8+
nemo_run/scripts/*

.github/workflows/test.yml

+19-6
Original file line numberDiff line numberDiff line change
@@ -27,17 +27,30 @@ jobs:
2727
git config --global user.name github-actions[bot]
2828
git config --global user.email 41898282+github-actions[bot]@users.noreply.github.com
2929
30-
- name: Run tests
31-
run: uv run -- pytest test/
32-
3330
- name: Run coverage
3431
run: |
35-
uv run -- coverage run -m pytest
32+
uv run -- coverage run --branch --source=nemo_run -a -m pytest
3633
uv run -- coverage report -m
3734
3835
- name: Run example notebooks
39-
run: uv run -- jupyter execute examples/**/*.ipynb
36+
run: |
37+
uv run -- coverage run --branch --source=nemo_run -a -m jupyter execute examples/**/*.ipynb
38+
uv run -- coverage report -m
4039
4140
- name: Run example scripts
4241
run: |
43-
cd examples/hello-world && uv run -- python hello_scripts.py
42+
uv run -- coverage run --branch --source=nemo_run -a examples/hello-world/hello_scripts.py
43+
uv run -- coverage report -m
44+
45+
- name: Generate report
46+
run: |
47+
uv run -- coverage xml
48+
uv run -- coverage report
49+
50+
- name: Upload coverage reports to Codecov
51+
uses: codecov/codecov-action@v5
52+
with:
53+
token: ${{ secrets.CODECOV_TOKEN }}
54+
files: coverage.xml
55+
verbose: true
56+
flags: cpu

codecov.yml

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
comment: false
2+
coverage:
3+
status:
4+
patch: false
5+
project: false
6+
fixes:
7+
- "/opt/NeMo-Run/::"

0 commit comments

Comments
 (0)