Skip to content

Commit 6d60438

Browse files
stanwuclaude
andcommitted
ci: add GitHub Actions workflow for lint, type check, and tests
Run ruff, mypy, bandit, and pytest across Python 3.9-3.13. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 78d667a commit 6d60438

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

.github/workflows/ci.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: CI
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+
matrix:
14+
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
15+
16+
steps:
17+
- uses: actions/checkout@v4
18+
19+
- name: Set up Python ${{ matrix.python-version }}
20+
uses: actions/setup-python@v5
21+
with:
22+
python-version: ${{ matrix.python-version }}
23+
24+
- name: Install dependencies
25+
run: pip install -r requirements-dev.txt
26+
27+
- name: Lint with ruff
28+
run: ruff check epub_safety_scanner.py test_epub_safety_scanner.py
29+
30+
- name: Format check with ruff
31+
run: ruff format --check epub_safety_scanner.py test_epub_safety_scanner.py
32+
33+
- name: Type check with mypy
34+
run: mypy epub_safety_scanner.py
35+
36+
- name: Security check with bandit
37+
run: bandit -c pyproject.toml -r epub_safety_scanner.py
38+
39+
- name: Run tests
40+
run: pytest -v

0 commit comments

Comments
 (0)