-
Notifications
You must be signed in to change notification settings - Fork 65
81 lines (69 loc) · 2.02 KB
/
run_tests.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
name: Tests
on:
push:
branches:
- master
tags:
- '*'
pull_request:
workflow_dispatch:
jobs:
tests:
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- name: Code style checks
os: ubuntu-latest
python: 3.x
toxenv: codestyle
- name: Build the docs
os: ubuntu-latest
python: 3.x
toxenv: build_docs
- name: Latest Python with minimal dependencies
os: ubuntu-latest
python: 3.x
toxenv: py3
- name: Python 3.11 with full coverage
os: ubuntu-latest
python: 3.11
toxenv: py311-alldeps-cov
- name: Python 3.7 with oldest supported version of all dependencies
os: ubuntu-latest
python: 3.7
toxenv: py37-oldestdeps
- name: Python 3.8 (MacOS X) with all optional dependencies
os: macos-latest
python: 3.8
toxenv: py38-alldeps
- name: Python 3.9 (Windows) with all optional dependencies
os: windows-latest
python: 3.9
toxenv: py39-alldeps
- name: Python 3.10 with all optional dependencies
os: ubuntu-latest
python: "3.10"
toxenv: py310-alldeps
- name: Download all of the builtins
os: ubuntu-latest
python: 3.x
toxenv: builtins
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- name: Install Python dependencies
run: python -m pip install --upgrade tox
- name: Run tests
run: tox ${{ matrix.toxargs }} -e ${{ matrix.toxenv }}
- name: Upload coverage to codecov
if: contains(matrix.toxenv,'-cov')
uses: codecov/codecov-action@v3
with:
file: ./coverage.xml