-
Notifications
You must be signed in to change notification settings - Fork 53
45 lines (43 loc) · 1.14 KB
/
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
name: tests
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-13]
python-version: ["3.7", "3.10"]
# exclude: # Python < v3.8 does not support Apple Silicon ARM64.
# - python-version: "3.7"
# os: macos-latest
# include: # So run those legacy versions on Intel CPUs.
# - python-version: "3.7"
# os: macos-13
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
cache-dependency-path: setup.py
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest
pip install -e .
- name: Setup display
if: runner.os == 'Linux'
run: |
export DISPLAY=:0.0
Xvfb :0 -screen 0 640x480x24 &
- name: Run tests
run: |
cd tests
pytest