Skip to content

Commit aec297e

Browse files
shixishclaude
andcommitted
Add GitHub Actions test workflow and commit uv.lock
Run pytest on push/PR to main across Python 3.10-3.13 using the pinned lockfile, plus a job that tests against the lowest allowed dependency versions to catch range-compatibility breaks the lockfile would hide. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 19b9a65 commit aec297e

3 files changed

Lines changed: 327 additions & 1 deletion

File tree

.github/workflows/tests.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Tests
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
jobs:
10+
test:
11+
runs-on: ubuntu-latest
12+
strategy:
13+
fail-fast: false
14+
matrix:
15+
python-version: ["3.10", "3.11", "3.12", "3.13"]
16+
17+
steps:
18+
- uses: actions/checkout@v4
19+
20+
- name: Install uv
21+
uses: astral-sh/setup-uv@v5
22+
with:
23+
python-version: ${{ matrix.python-version }}
24+
25+
- name: Install dependencies (locked)
26+
run: uv sync --frozen --extra dev
27+
28+
- name: Run tests
29+
run: uv run pytest
30+
31+
# Catch breakage against the lowest dependency versions our ranges allow,
32+
# which the pinned lockfile would otherwise hide.
33+
test-lowest:
34+
runs-on: ubuntu-latest
35+
steps:
36+
- uses: actions/checkout@v4
37+
38+
- name: Install uv
39+
uses: astral-sh/setup-uv@v5
40+
with:
41+
python-version: "3.10"
42+
43+
- name: Install lowest allowed dependencies
44+
run: uv sync --resolution lowest-direct --extra dev
45+
46+
- name: Run tests
47+
run: uv run pytest

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
__pycache__
44
.pytest_cache
55
.env
6-
uv.lock
76
dist/
87
build/
98
*.egg-info/

0 commit comments

Comments
 (0)