forked from auto-pts/auto-pts
-
Notifications
You must be signed in to change notification settings - Fork 7
55 lines (41 loc) · 1.54 KB
/
full-style-matrix.yml
File metadata and controls
55 lines (41 loc) · 1.54 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
name: Full Build & Style Matrix
on:
push:
branches: [ "main", "master" ]
pull_request:
branches: [ "main", "master" ]
jobs:
test_and_style:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
name: Build & Style (${{ matrix.python-version }})
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Upgrade pip
run: python -m pip install --upgrade pip
- name: Install base test dependencies
run: |
pip install flake8 pytest wheel
cat autoptsclient_requirements.txt | xargs -n 1 pip install || true
cat autoptsserver_requirements.txt | xargs -n 1 pip install || true
- name: Run Ruff (Python >= 3.9)
if: startsWith(matrix.python-version, '3.9') || startsWith(matrix.python-version, '3.10') || startsWith(matrix.python-version, '3.11') || startsWith(matrix.python-version, '3.12') || startsWith(matrix.python-version, '3.13')
run: |
pip install -r requirements_ci.txt
ruff check .
- name: Compile (only if file exists)
run: |
python -m py_compile autoptsserver.py || true
python -m py_compile autoptsclient_bot.py || true
- name: Run unit tests with pytest
run: pytest ./test/unittests.py
- name: Test MMI parser
run: python -m test.test-mmi-parser