@@ -8,29 +8,96 @@ name: CI
88permissions :
99 contents : read
1010
11+ env :
12+ DEFAULT_PYTHON : " 3.14"
13+
1114jobs :
1215 lint :
16+ name : Lint
1317 runs-on : ubuntu-latest
14- strategy :
15- matrix :
16- python-version : ["3.12"]
1718
1819 steps :
19- - uses : actions/checkout@v5
20+ - &checkout
21+ name : Check out the repository
22+ uses : actions/checkout@v5
23+ with :
24+ fetch-depth : 2
2025
21- - name : Set up Python ${{ matrix.python-version }}
22- uses : actions/setup-python@v6
26+ - &setup-python
27+ name : Set up Python ${{ env.DEFAULT_PYTHON }}
28+ 2329 with :
24- python-version : ${{ matrix.python-version }}
30+ python-version : ${{ env.DEFAULT_PYTHON }}
31+ check-latest : true
2532
26- - name : Install UV
33+ - &setup-uv
34+ name : Install UV
2735 uses : astral-sh/setup-uv@v7
2836 with :
2937 enable-cache : true
3038 version-file : " pyproject.toml"
3139
32- - name : Install dependencies
40+ - &install-dependencies
41+ name : Install dependencies
3342 run : uv sync --all-extras --frozen
3443
3544 - name : Lint
3645 run : uv run --with tox-uv tox -e lint
46+
47+ build :
48+ if : github.repository_owner == 'PyCQA'
49+ name : Build
50+ runs-on : ubuntu-latest
51+
52+ steps :
53+ - *checkout
54+ - *setup-python
55+ - *setup-uv
56+
57+ - name : Build package
58+ run : uv build
59+
60+ test :
61+ name : Tests
62+ strategy :
63+ fail-fast : false
64+ matrix :
65+ python-version : ["3.10", "3.11", "3.12", "3.13", "3.14"]
66+ os : [ubuntu-latest, macos-latest, windows-latest]
67+ runs-on : ${{ matrix.os }}
68+ env :
69+ FORCE_COLOR : 1
70+
71+ steps :
72+ - *checkout
73+
74+ - name : Set up Python ${{ matrix.python-version }}
75+ uses : actions/setup-python@v6
76+ with :
77+ python-version : ${{ matrix.python-version }}
78+ allow-prereleases : true
79+ check-latest : true
80+
81+ - *setup-uv
82+ - *install-dependencies
83+
84+ - name : Run tests
85+ run : uv run --with tox-uv tox -e py,coverage_report-ci
86+
87+ - name : Report Coverage
88+ if : matrix.os == 'ubuntu-latest' && matrix.python-version == ${{ env.DEFAULT_PYTHON }}
89+ uses : codecov/codecov-action@v5
90+
91+
92+ integration :
93+ name : Integration tests
94+ runs-on : ubuntu-latest
95+
96+ steps :
97+ - *checkout
98+ - *setup-python
99+ - *setup-uv
100+ - *install-dependencies
101+
102+ - name : Test integration
103+ run : ./scripts/test_integration.sh
0 commit comments