-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (54 loc) · 1.29 KB
/
ci.yml
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
name: Build & Test
"on":
push:
branches:
- "*"
pull_request:
branches:
- "*"
schedule:
- cron: 01 13 * * SAT
jobs:
test:
name: Build & Test
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- windows-latest
- macos-latest
python-version:
- "3.9"
- "3.10"
- "3.11"
- "3.12"
steps:
- uses: actions/checkout@85e6279cec87321a52edac9c87bce653a07cf6c2
- uses: astral-sh/setup-uv@1ffa6dc3ad7b3dcf4bb2bd5fe8e5725861be5094
id: setup-uv
with:
enable-cache: true
- run: echo "Installed uv version is ${{ steps.setup-uv.outputs.uv-version }}"
- name: Create venv and sync deps
run: |
uv venv --python ${{ matrix.python-version }}
uv sync
- name: Run tests (Windows)
if: runner.os == 'Windows'
run: |
. .venv/Scripts/activate.ps1
pytest -v
shell: pwsh
- name: Run tests (Linux/macOS)
if: runner.os != 'Windows'
run: |
. .venv/bin/activate
pytest -v
required-check:
name: All Tests Passed
needs: test
runs-on: ubuntu-latest
steps:
- run: echo "All tests passed!"