-
Notifications
You must be signed in to change notification settings - Fork 4
44 lines (38 loc) · 1.03 KB
/
test-code.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
name: test-code
on: [push, pull_request]
# Cancel if a newer run is started
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
run_pytest:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.10.2]
steps:
# Checkout code and install miniconda + environment
- uses: actions/checkout@v4
- uses: mamba-org/setup-micromamba@v1
with:
init-shell: bash
create-args: >-
python=${{ matrix.python-version }}
pip
environment-file: environment.yml
environment-name: anglerfish-dev
# Install Anglerfish
- shell: bash -l {0}
name: Install Anglerfish
run: |
python -m pip install .
# Install Pytest
- shell: bash -l {0}
name: Install Pytest
run: |
python -m pip install pytest
# Run Pytest
- shell: bash -l {0}
name: Run Pytest
run: |
pytest .