-
-
Notifications
You must be signed in to change notification settings - Fork 35
96 lines (87 loc) · 2.17 KB
/
tox.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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
name: tox
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build:
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
name: [
"docs",
"py36",
"py37",
"py38",
"py39",
"py310",
"lint",
"packaging",
]
os: [
"ubuntu-latest",
]
include:
- name: docs
python: "3.6"
os: ubuntu-latest
tox_env: docs
- name: py36
python: "3.6"
os: ubuntu-latest
tox_env: py36
- name: py37
python: "3.7"
os: ubuntu-latest
tox_env: py37
- name: py38
python: "3.8"
os: ubuntu-latest
tox_env: py38
- name: py39
python: "3.9"
os: ubuntu-latest
tox_env: py39
- name: py310
python: "3.10"
os: ubuntu-latest
tox_env: py310
- name: py311
python: "~3.11.0-0" # see https://github.com/actions/setup-python/issues/213#issuecomment-1146676713
os: ubuntu-latest
tox_env: py311
- name: "lint"
python: "3.7"
os: ubuntu-latest
tox_env: "lint"
- name: "packaging"
python: "3.7"
os: ubuntu-latest
tox_env: "packaging"
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install tox
- name: Test
run: "tox -e ${{ matrix.tox_env }}"
check: # This job does nothing and is only used for the branch protection
if: always()
needs:
- build
runs-on: ubuntu-latest
steps:
- name: Decide whether the needed jobs succeeded or failed
uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}