Skip to content

Commit 8119505

Browse files
committed
Fix CodeCov reporting
1 parent 48698c8 commit 8119505

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

.github/workflows/ci.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,11 @@ jobs:
5959
- uses: astral-sh/setup-uv@v7
6060
with:
6161
python-version: ${{ matrix.python-version }}
62-
- run: uv run --with Django~=${{ matrix.django-version }}.0 pytest -m "not selenium"
62+
- run: uv run --with Django~=${{ matrix.django-version }}.0 pytest --cov-report=xml -m "not selenium"
6363
- uses: codecov/codecov-action@v5
64+
with:
65+
token: ${{ secrets.CODECOV_TOKEN }}
66+
flags: python-${{ matrix.python-version }}
6467
Selenium:
6568
needs:
6669
- standardjs
@@ -72,5 +75,8 @@ jobs:
7275
curl -LsSfO https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
7376
sudo dpkg -i google-chrome-stable_current_amd64.deb || sudo apt-get -f install -y
7477
- uses: astral-sh/setup-uv@v7
75-
- run: uv run pytest -m selenium
78+
- run: uv run pytest --cov-report=xml -m selenium
7679
- uses: codecov/codecov-action@v5
80+
with:
81+
token: ${{ secrets.CODECOV_TOKEN }}
82+
flags: selenium

pyproject.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ write_to = "django_select2/_version.py"
7171

7272
[tool.pytest.ini_options]
7373
minversion = "6.0"
74-
addopts = "--cov --tb=short -rxs"
74+
addopts = "--cov --cov-report=xml --cov-report=term --tb=short -rxs"
7575
testpaths = ["tests"]
7676
DJANGO_SETTINGS_MODULE = "tests.testapp.settings"
7777
filterwarnings = ["ignore::PendingDeprecationWarning", "error::RuntimeWarning"]
@@ -81,6 +81,7 @@ source = ["django_select2"]
8181

8282
[tool.coverage.report]
8383
show_missing = true
84+
skip_covered = true
8485

8586
[tool.isort]
8687
atomic = true

0 commit comments

Comments
 (0)