Skip to content

Commit bd47bf5

Browse files
committed
adding python-test.yml
this could replace travis.yml Signed-off-by: rosjat <markus.rosjat@gmail.com>
1 parent e6cf132 commit bd47bf5

1 file changed

Lines changed: 48 additions & 0 deletions

File tree

.github/python-test.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Python Tests
2+
3+
on:
4+
push:
5+
branches:
6+
- main # Trigger on push to the main branch (or adjust for other branches)
7+
pull_request:
8+
branches:
9+
- main # Trigger on pull requests to the main branch
10+
11+
jobs:
12+
test:
13+
runs-on: ubuntu-latest # Use an Ubuntu runner
14+
15+
strategy:
16+
matrix:
17+
python-version: [3.7, 3.8, 3.9, 3.10, 3.11, 3.12, 3.13] # Python versions for the matrix
18+
include:
19+
- python-version: 3.8
20+
pytest-mypy: "--mypy"
21+
- python-version: 3.9
22+
pytest-mypy: "--mypy"
23+
- python-version: 3.10
24+
pytest-mypy: "--mypy"
25+
- python-version: 3.11
26+
pytest-mypy: "--mypy"
27+
- python-version: 3.12
28+
pytest-mypy: "--mypy"
29+
- python-version: 3.13
30+
pytest-mypy: "--mypy"
31+
32+
steps:
33+
- name: Checkout repository
34+
uses: actions/checkout@v4
35+
36+
- name: Set up Python
37+
uses: actions/setup-python@v5
38+
with:
39+
python-version: ${{ matrix.python-version }}
40+
41+
- name: Install dependencies
42+
run: |
43+
python -m pip install --upgrade pip
44+
pip install .[dev]
45+
46+
- name: Run tests
47+
run: |
48+
py.test -vvv ${{ matrix.pytest-mypy }}

0 commit comments

Comments
 (0)