-
Notifications
You must be signed in to change notification settings - Fork 1
48 lines (41 loc) · 1.52 KB
/
test.yml
File metadata and controls
48 lines (41 loc) · 1.52 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Tests
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
test:
# Tests run on Ubuntu only. Windows runs the `build` workflow's
# wheel-install + `--version` / `--help` / `cfg ls` smoke test
# (which exercises the real cross-platform code paths the user
# actually hits — lock, watcher entry points, settings I/O).
# Adding the Windows pytest matrix back is tracked as HANDOFF #4
# follow-up: the test suite has POSIX-shaped path fixtures
# (hard-coded `/Users/...` literals, raw `Path.resolve()` that
# drive-prefixes on Windows) and a Windows port needs a path-
# comparison helper + per-test fixtures, not just a CI matrix.
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
python-version: ["3.11", "3.12"]
steps:
- uses: actions/checkout@v5
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e ".[dev]"
- name: Run tests
run: |
# Skip performance tests in CI as they require specific test data
python -m pytest tests/ -v --tb=short --cov=stackunderflow --cov-report=term-missing --ignore=tests/stackunderflow/test_performance.py
- name: Check test coverage
run: |
# Fail if coverage is below 60%
coverage report --fail-under=60