-
Notifications
You must be signed in to change notification settings - Fork 0
78 lines (69 loc) · 1.91 KB
/
ci.yml
File metadata and controls
78 lines (69 loc) · 1.91 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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
name: CI
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
test:
name: Test on ${{ matrix.os }} with Python ${{ matrix.python-version }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- ubuntu-22.04
- ubuntu-20.04
- macos-latest
- macos-12
- windows-latest
python-version: ['3.10', '3.11', '3.12', '3.13']
exclude:
# Reduce matrix size - only test Python 3.12 on older OS versions
- os: ubuntu-20.04
python-version: '3.10'
- os: ubuntu-20.04
python-version: '3.11'
- os: ubuntu-20.04
python-version: '3.13'
- os: macos-12
python-version: '3.10'
- os: macos-12
python-version: '3.11'
- os: macos-12
python-version: '3.13'
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install system dependencies (Linux)
if: runner.os == 'Linux'
run: |
sudo apt-get update -qq
sudo apt-get install -y jq curl
- name: Install system dependencies (macOS)
if: runner.os == 'macOS'
run: |
brew install jq
- name: Install system dependencies (Windows)
if: runner.os == 'Windows'
shell: bash
run: |
choco install -y jq curl
- name: Run tests
shell: bash
run: |
chmod +x tests/run_tests.sh
./tests/run_tests.sh
- name: Upload test results
if: always()
uses: actions/upload-artifact@v4
with:
name: test-results-${{ matrix.os }}-py${{ matrix.python-version }}
path: |
tests/*.log
tests/results/
retention-days: 7