Skip to content

Commit 0929bec

Browse files
committed
Measure test coverage
1 parent b08a4b9 commit 0929bec

File tree

2 files changed

+32
-1
lines changed

2 files changed

+32
-1
lines changed

.github/workflows/coverage.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: coverage
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
jobs:
10+
report:
11+
runs-on: ubuntu-22.04
12+
strategy:
13+
matrix:
14+
python-version: ["3.10"]
15+
steps:
16+
- uses: actions/checkout@v3
17+
- name: Set up Python ${{ matrix.python-version }}
18+
uses: actions/setup-python@v3
19+
with:
20+
python-version: ${{ matrix.python-version }}
21+
22+
- name: Install packages
23+
run: |
24+
python -m pip install --upgrade pip wheel setuptools
25+
python -m pip install ".[test]"
26+
pip list
27+
28+
- name: Test NetworkX
29+
run: |
30+
python -m pytest --cov=lazy_loader --doctest-modules --durations=20
31+
codecov

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ dynamic = ["description"]
2121

2222

2323
[project.optional-dependencies]
24-
test = ["pytest >= 7"]
24+
test = ["pytest >= 7.1", "pytest-cov >= 3.0", "codecov >= 2.1"]
2525
lint = ["pre-commit >= 2.20"]
2626

2727
[project.urls]

0 commit comments

Comments
 (0)