-
Notifications
You must be signed in to change notification settings - Fork 6
36 lines (33 loc) · 945 Bytes
/
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
name: Test
on: [push, pull_request, workflow_call]
env:
PACKAGE: radicli
jobs:
test:
name: Run tests
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ['3.8', '3.9', '3.10']
steps:
- uses: actions/checkout@v1
with:
submodules: true
- uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install
run: pip install -r requirements.txt
- name: Run pyright
run: python -m pyright ${{ env.PACKAGE }}
- name: Build sdist
run: python setup.py sdist
- name: Remove package directory
run: rm -rf ${{ env.PACKAGE }}
shell: bash
- name: Install from sdist
run: pip install dist/*.tar.gz
shell: bash
- name: Run pytest
run: python -m pytest --pyargs ${{ env.PACKAGE }}