-
Notifications
You must be signed in to change notification settings - Fork 1
49 lines (46 loc) · 1.41 KB
/
python-app.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
# Modified from https://github.com/marketplace/actions/install-poetry-action
name: test
on:
pull_request:
branches:
- main
paths-ignore:
- "paper/**"
push:
branches:
- main
jobs:
test:
strategy:
fail-fast: false
matrix:
os: [ "ubuntu-latest", "macos-latest" ]
python-version: [ "3.8", "3.9" ]
runs-on: ${{ matrix.os }}
steps:
#----------------------------------------------
# check-out repo and set-up python
#----------------------------------------------
- name: Check out repository
uses: actions/checkout@v2
- name: Set up python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
#----------------------------------------------
# ----- install & configure poetry -----
#----------------------------------------------
- name: Install Poetry
uses: Gr1N/setup-poetry@v8
- name: Install dependencies
run: |
poetry config virtualenvs.in-project true
poetry install
#----------------------------------------------
# run test suite
#----------------------------------------------
- name: Run tests
run: |
source .venv/bin/activate
python -c "import pxmcmc; print(pxmcmc.__version__)"
pytest tests/