-
Notifications
You must be signed in to change notification settings - Fork 48
95 lines (81 loc) · 2.28 KB
/
test.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
name: Test
on:
push:
branches:
- main
pull_request:
paths-ignore:
- "**.md"
- "**.rst"
jobs:
build_wheels:
name: |-
Build wheels on ${{ matrix.os }} with
windows_cross_compile=${{ matrix.windows_cross_compile }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-11, ubuntu-20.04]
windows_cross_compile: [false, true]
exclude:
- os: macos-11
windows_cross_compile: true
steps:
- name: Install dependencies
run: |-
sudo apt-get update
sudo apt-get install -y mingw-w64
if: ${{ matrix.windows_cross_compile }}
- uses: actions/checkout@v3
- name: Build wheels
run: bash build.sh
env:
WINDOWS_CROSS_COMPILE: ${{ matrix.windows_cross_compile }}
- name: Upload artefacts
uses: actions/upload-artifact@v3
with:
name: artefacts
path: btrack/libs/*
if-no-files-found: error
test:
needs: build_wheels
name: ${{ matrix.os }} py${{ matrix.python-version }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11"]
os: [ubuntu-latest]
include:
- os: macos-11
python-version: "3.11"
- os: macos-latest
python-version: "3.11"
- os: windows-2019
python-version: "3.11"
- os: windows-latest
python-version: "3.11"
- os: ubuntu-20.04
python-version: "3.11"
steps:
- uses: actions/checkout@v3
- name: Download artefacts
uses: actions/download-artifact@v3
with:
name: artefacts
path: btrack/libs
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: "pip"
cache-dependency-path: "pyproject.toml"
# these libraries enable testing on Qt on linux
- uses: tlambert03/setup-qt-libs@v1
- name: Install dependencies
run: python -m pip install tox tox-gh-actions
- name: Test with tox
run: tox run
env:
OS: ${{ matrix.os }}
- name: Coverage
uses: codecov/codecov-action@v3