-
Notifications
You must be signed in to change notification settings - Fork 53
121 lines (106 loc) · 3.32 KB
/
ci.yaml
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
name: CI
on:
# run every Sunday at 4:44 UTC
schedule:
- cron: "44 4 * * 0"
push:
branches:
- "main"
pull_request:
branches:
- "main"
concurrency:
group: "${{ github.ref }}-${{ github.head_ref }}"
cancel-in-progress: true
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macOS-latest]
python-version: ["2.7", "3.6", "3.7", "3.8", "3.9", "3.10", "3.11"]
gromacs-version: ["2021.1"]
# Test other GROMACS versions selectively on a recent Python.
# On macOS only test one GROMACS version and two Python versions
# to keep the testing matrix manageable.
exclude:
- os: macOS-latest
python-version: "3.6"
- os: macOS-latest
python-version: "3.7"
- os: macOS-latest
python-version: "3.8"
- os: macOS-latest
python-version: "3.9"
- os: macOS-latest
python-version: "3.10"
include:
- os: ubuntu-latest
python-version: "2.7"
gromacs-version: "4.6.5"
- os: ubuntu-latest
python-version: "3.10"
gromacs-version: "4.6.5"
- os: ubuntu-latest
python-version: "3.10"
gromacs-version: "2018.6"
- os: ubuntu-latest
python-version: "3.10"
gromacs-version: "2019.1"
- os: ubuntu-latest
python-version: "3.10"
gromacs-version: "2020.6"
- os: ubuntu-latest
python-version: "3.10"
gromacs-version: "2022.4"
env:
MPLBACKEND: agg
steps:
- uses: actions/checkout@v3
- name: setup miniconda (Python ${{ matrix.python-version }})
uses: conda-incubator/setup-miniconda@v2
with:
python-version: ${{ matrix.python-version }}
auto-update-conda: true
mamba-version: "*"
channels: conda-forge,bioconda,defaults
channel-priority: true
show-channel-urls: true
- name: Conda info
shell: bash -l {0}
run: |
conda info
conda list
conda config --show-sources
conda config --show
- name: Python version ${{ matrix.python-version }}
shell: bash -l {0}
run: |
python -c "import sys; print(sys.version)"
- name: Install package dependencies
shell: bash -l {0}
run: |
mamba install six numpy scipy matplotlib-base pandas numkit
- name: Install pytest and plugins
shell: bash -l {0}
run: |
mamba install pytest pytest-pep8 pytest-cov codecov
- name: Install GROMACS (${{ matrix.gromacs-version }})
shell: bash -l {0}
run: |
mamba install 'gromacs==${{ matrix.gromacs-version }}' pocl
- name: Install package
shell: bash -l {0}
run: |
python -m pip install --no-deps .
- name: Run tests
shell: bash -l {0}
run: |
pytest -v --disable-pytest-warnings --durations=20 --low-performance --cov=gromacs --cov-report=xml --color=yes ./tests
- name: Codecov
uses: codecov/codecov-action@v3
with:
name: codecov-${{ matrix.os }}-py${{ matrix.python-version }}
file: ./coverage.xml
fail_ci_if_error: false