Skip to content

Commit 7fc2f5f

Browse files
ci: add PR-gate workflow for lint and tests
Existing main.yml only fires on workflow_dispatch (release path), so unit tests never ran on PRs. Add a workflow that runs pytest on every PR (and pushes to main) across Python 3.11 and 3.12. Lint is left as a follow-up — src/ currently has 10 pre-existing E501 violations that would block any gate; cleaning those up is a separate change. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent 29f169f commit 7fc2f5f

1 file changed

Lines changed: 36 additions & 0 deletions

File tree

.github/workflows/test.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Lint and Test
2+
3+
on:
4+
pull_request:
5+
branches: [main, "feat/**", "fix/**"]
6+
push:
7+
branches: [main]
8+
9+
jobs:
10+
lint-and-test:
11+
runs-on: ubuntu-latest
12+
strategy:
13+
fail-fast: false
14+
matrix:
15+
python-version: ["3.11", "3.12"]
16+
steps:
17+
- uses: actions/checkout@v4
18+
19+
- uses: actions/setup-python@v5
20+
with:
21+
python-version: ${{ matrix.python-version }}
22+
23+
- name: Install uv
24+
uses: astral-sh/setup-uv@v6
25+
with:
26+
version: "0.6.14"
27+
enable-cache: true
28+
29+
- name: Install dependencies
30+
run: uv sync --dev
31+
32+
- name: Create test env
33+
run: cp tests/sample.env tests/.env
34+
35+
- name: Tests (pytest)
36+
run: uv run pytest tests/ -v

0 commit comments

Comments
 (0)