Skip to content

Commit af73b3d

Browse files
author
Gabriele Picco
committed
✅ Add code coverage
1 parent 812e6dc commit af73b3d

File tree

5 files changed

+10
-3
lines changed

5 files changed

+10
-3
lines changed

.github/workflows/python-tests.yml

+3-1
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,6 @@ jobs:
3535
python -m spacy download en_core_web_sm
3636
- name: Test with pytest
3737
run: |
38-
python -m pytest -v
38+
python -m pytest --cov -v
39+
- name: Upload coverage to Codecov
40+
uses: codecov/codecov-action@v3

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -129,3 +129,4 @@ dmypy.json
129129
.pyre/
130130
.idea/
131131
.DS_Store
132+
codecov

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
<a href="https://pypi.org/project/zshot/"><img src="https://img.shields.io/pypi/v/zshot" /></a>
1515
<a href="https://pypi.org/project/zshot/"><img src="https://img.shields.io/pypi/dm/zshot" /></a>
1616
<a href="https://github.com/IBM/zshot/actions/workflows/python-tests.yml"> <img alt="Build" src="https://github.com/IBM/zshot/actions/workflows/python-tests.yml/badge.svg" /></a>
17+
<a href="https://app.codecov.io/github/ibm/zshot"> <img alt="Build" src="https://codecov.io/github/ibm/zshot/branch/main/graph/badge.svg" /></a>
1718

1819
</p>
1920
</div>

docs/index.md

+1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
<a href="https://pypi.org/project/zshot/"><img src="https://img.shields.io/pypi/v/zshot" /></a>
1313
<a href="https://pypi.org/project/zshot/"><img src="https://img.shields.io/pypi/dm/zshot" /></a>
1414
<a href="https://github.com/IBM/zshot/actions/workflows/python-tests.yml"> <img alt="Build" src="https://github.com/IBM/zshot/actions/workflows/python-tests.yml/badge.svg" /></a>
15+
<a href="https://app.codecov.io/github/ibm/zshot"> <img alt="Build" src="https://codecov.io/github/ibm/zshot/branch/main/graph/badge.svg" /></a>
1516

1617
</p>
1718
</div>

requirements/test.txt

+4-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
pytest>=5.0
1+
pytest>=7.0
2+
pytest-cov>=3.0.0
23
setuptools~=60.0.0
34
flair==0.11.3
4-
flake8>=4.0.1
5+
flake8>=4.0.1
6+
coverage>=6.4.1

0 commit comments

Comments
 (0)