Skip to content

Commit 7afd045

Browse files
committed
try without deps
1 parent dfae863 commit 7afd045

File tree

1 file changed

+63
-12
lines changed

1 file changed

+63
-12
lines changed

.github/workflows/test.yml

Lines changed: 63 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,12 @@ jobs:
3232
- '3.2' # LTS April 2024
3333
- '4.2' # LTS April 2026
3434
- '5.1' # December 2025
35-
drf-version:
36-
- '>=3.14.0,<3.15.0'
37-
- '^3.15'
38-
filter-version:
39-
- '23.5'
40-
- '24.0'
35+
# drf-version:
36+
# - '>=3.14.0,<3.15.0'
37+
# - '^3.15'
38+
# filter-version:
39+
# - '23.5'
40+
# - '24.0'
4141
exclude:
4242

4343
- drf-version: '^3.15'
@@ -139,8 +139,6 @@ jobs:
139139
poetry run pip install --upgrade pip
140140
sed -i 's/^python = .*/python = "^${{ matrix.python-version }}"/' pyproject.toml
141141
poetry add django@^${{ matrix.django-version }}
142-
poetry add django-filter@^${{ matrix.filter-version }} --optional
143-
poetry add djangorestframework@"${{ matrix.drf-version }}" --optional
144142
poetry install --no-interaction --with ${{ matrix.psycopg-version }}
145143
- name: No Optional Dependency Unit Tests
146144
run: |
@@ -172,11 +170,13 @@ jobs:
172170
- name: Run Full Unit Tests
173171
run: |
174172
poetry run pytest --cov-append
175-
- name: Upload coverage to Codecov
176-
uses: codecov/codecov-action@v4
173+
mv py${{ matrix.python-version }}-dj${{ matrix.django-version }}-${{ matrix.psycopg-version }}-pg${{ matrix.postgres-version }}.coverage
174+
175+
- name: Store coverage files
176+
uses: actions/upload-artifact@v4
177177
with:
178-
token: ${{ secrets.CODECOV_TOKEN }}
179-
file: ./coverage.xml
178+
name: coverage-py${{ matrix.python-version }}-dj${{ matrix.django-version }}-${{ matrix.psycopg-version }}-pg${{ matrix.postgres-version }}
179+
path: py${{ matrix.python-version }}-dj${{ matrix.django-version }}-${{ matrix.psycopg-version }}-pg${{ matrix.postgres-version }}.coverage
180180

181181
sqlite:
182182
runs-on: ubuntu-latest
@@ -587,3 +587,54 @@ jobs:
587587
- name: Run Full Unit Tests
588588
run: |
589589
poetry run pytest -s
590+
591+
592+
coverage-combine:
593+
needs: [postgres, sqlite, mysql, mariadb, oracle]
594+
runs-on: ubuntu-latest
595+
596+
steps:
597+
- name: Install Emacs
598+
if: ${{ github.event.inputs.debug == 'on' }}
599+
run: |
600+
sudo apt install emacs
601+
- name: Setup tmate session
602+
if: ${{ github.event.inputs.debug == 'on' }}
603+
uses: mxschmitt/action-tmate@v3
604+
with:
605+
detached: true
606+
timeout-minutes: 60
607+
- uses: actions/checkout@v4
608+
- uses: actions/setup-python@v5
609+
with:
610+
python-version: '3.12'
611+
612+
- name: Install Poetry
613+
uses: snok/install-poetry@v1
614+
with:
615+
virtualenvs-create: true
616+
virtualenvs-in-project: true
617+
618+
- name: Install Release Dependencies
619+
run: |
620+
poetry config virtualenvs.in-project true
621+
poetry run pip install --upgrade pip
622+
poetry install
623+
624+
- name: Get coverage files
625+
uses: actions/download-artifact@v4
626+
with:
627+
pattern: coverage-*
628+
merge-multiple: true
629+
630+
- run: ls -la *.coverage
631+
- run: poetry run coverage combine --keep *.coverage
632+
- run: poetry run coverage report
633+
- run: poetry run coverage xml
634+
635+
- name: Upload coverage to Codecov
636+
uses: codecov/codecov-action@v4
637+
with:
638+
token: ${{ secrets.CODECOV_TOKEN }}
639+
file: ./coverage.xml
640+
verbose: true

0 commit comments

Comments
 (0)