Repository navigation
56 lines (52 loc) · 1.77 KB
/
Copy pathpython-test.yml
File metadata and controls
56 lines (52 loc) · 1.77 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
49
50
51
52
53
54
55
56
name: Python Test
on:
push:
branches: ["main"]
paths-ignore: ["README.md", "docs", ".github"]
pull_request:
branches: ["main"]
paths-ignore: ["README.md", "docs", ".github"]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.14"]
steps:
- uses: actions/checkout@v4
with:
submodules: "recursive"
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: curl -LsSf https://astral.sh/uv/install.sh | sh
- name: Install project dependencies
run: uv sync --all-extras --all-groups
- name: ty check
run: uv run ty check pgdevkit
- name: Test with pytest
run: uv run -m pytest --capture=tee-sys --maxfail=3 -m "not mssql" tests
mssql-test:
# Separate job (not folded into `build`) so a live SQL Server -- a much
# larger image and slower cold start than the Postgres container --
# never slows down or blocks the fast, always-run Postgres suite above.
# mssql-python bundles its own ODBC driver, so unlike pyodbc this needs
# no system driver package install here.
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: "recursive"
- name: Set up Python 3.14
uses: actions/setup-python@v5
with:
python-version: "3.14"
- name: Install uv
run: curl -LsSf https://astral.sh/uv/install.sh | sh
- name: Install project dependencies
run: uv sync --all-extras --all-groups
- name: Run MSSQL-only tests
run: uv run -m pytest --capture=tee-sys --maxfail=3 -m mssql tests