-
Notifications
You must be signed in to change notification settings - Fork 157
42 lines (37 loc) · 1.41 KB
/
main.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
# This is a basic workflow to help you get started with Actions
name: CI
# Controls when the action will run.
on: [push, pull_request, workflow_dispatch]
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["2.7", "3.8", "3.9", "3.10", "3.11"]
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: MatteoH2O1999/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Add conda to system path
run: |
echo $CONDA/bin >> $GITHUB_PATH
- name: Install dependencies
run: |
if [[ ${{ matrix.python-version }} != "2.7" ]]; then conda config --add channels conda-forge; fi
conda create --yes -n test python=${{ matrix.python-version }}
source activate test
conda install --yes numpy scipy nose requests
if [[ ${{ matrix.python-version }} == "2.7" ]]; then conda install --yes unittest2; else conda install --yes pdbfixer mdtraj; fi
pip install mmtf-python scikit-learn
pip install .
python setup.py build_ext --inplace --force
- name: Test with pytest
run: |
source activate test
conda install --yes pytest
pytest