Skip to content

Commit 8660b63

Browse files
committed
chore: streamline CI with UV and tox-gh-actions
1 parent 27e8773 commit 8660b63

File tree

2 files changed

+5
-30
lines changed

2 files changed

+5
-30
lines changed

.github/workflows/test.yml

Lines changed: 5 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ jobs:
1515
strategy:
1616
fail-fast: false
1717
matrix:
18+
# needs to included every supported python version
1819
python-version:
1920
- '3.10'
2021
- '3.11'
@@ -50,29 +51,11 @@ jobs:
5051
with:
5152
python-version: ${{ matrix.python-version }}
5253

54+
- name: Install uv
55+
uses: hynek/setup-cached-uv@v2
5356

54-
- name: Get pip cache dir
55-
id: pip-cache
56-
run: |
57-
echo "::set-output name=dir::$(pip cache dir)"
58-
59-
- name: Cache
60-
uses: actions/cache@v4
61-
with:
62-
path: ${{ steps.pip-cache.outputs.dir }}
63-
key:
64-
${{ matrix.python-version }}-v1-${{ hashFiles('**/pyproject.toml') }}-${{ hashFiles('**/tox.ini') }}
65-
restore-keys: |
66-
${{ matrix.python-version }}-v1-
67-
68-
- name: Install Python dependencies
69-
run: |
70-
python -m pip install --upgrade pip
71-
python -m pip install --upgrade tox tox-gh-actions
72-
73-
- name: Tox tests
74-
run: |
75-
tox -v
57+
- name: 🧪 Run tox targets for Python ${{ matrix.python-version }}
58+
run: uvx --with tox-uv --with tox-gh-actions tox -v
7659
env:
7760
DJANGO: ${{ matrix.django-version }}
7861

tox.ini

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,14 +22,6 @@ python =
2222
3.13: py313
2323
3.14: py314
2424

25-
[gh-actions:env]
26-
DJANGO =
27-
4.2: dj42
28-
5.0: dj50
29-
5.1: dj51
30-
5.2: dj52
31-
main: djmain
32-
3325
[testenv]
3426
commands =
3527
pytest {posargs}

0 commit comments

Comments
 (0)