-
Notifications
You must be signed in to change notification settings - Fork 54
134 lines (119 loc) · 3.94 KB
/
Copy pathci.yaml
File metadata and controls
134 lines (119 loc) · 3.94 KB
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
122
123
124
125
126
127
128
129
130
131
132
133
134
name: CI
on:
# run every month on day 14 and 28 at 4:44 UTC
schedule:
- cron: "44 4 14,28 * *"
push:
branches:
- "main"
pull_request:
branches:
- "main"
concurrency:
group: "${{ github.ref }}-${{ github.head_ref }}"
cancel-in-progress: true
defaults:
run:
shell: bash -l {0}
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
gromacs-version: ["2023.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.
include:
- os: ubuntu-latest
python-version: "3.11"
gromacs-version: "4.6.5"
- os: ubuntu-latest
python-version: "3.11"
gromacs-version: "2018.6"
- os: ubuntu-latest
python-version: "3.11"
gromacs-version: "2019.1"
- os: ubuntu-latest
python-version: "3.11"
gromacs-version: "2020.6"
- os: ubuntu-latest
python-version: "3.11"
gromacs-version: "2021.1"
- os: ubuntu-latest
python-version: "3.11"
gromacs-version: "2022.4"
- os: ubuntu-latest
python-version: "3.11"
gromacs-version: "2023.4"
- os: ubuntu-latest
python-version: "3.11"
gromacs-version: "2024.2"
# explicitly include a few macOS runners; finding a version that works
# on the GH runners is tricky (eg some are compiled for rdtscp CPU instructions
# that are not available); 2018.6 (bioconda) worked for a while, but then stopped
# being resolved. 2024.2 (conda-forge) runs at the moment
- os: macOS-latest
python-version: "3.11"
gromacs-version: "2024.2"
- os: macOS-latest
python-version: "3.12"
gromacs-version: "2024.2"
env:
MPLBACKEND: agg
steps:
- name: git checkout
uses: actions/checkout@v4
with:
fetch-tags: true
- name: micromamba package and testing environment installation (Python ${{ matrix.python-version }}, GROMACS ${{ matrix.gromacs-version }})
uses: mamba-org/setup-micromamba@v2
with:
environment-file: ci/conda-envs/test_env.yaml
condarc: |
channels:
- conda-forge
- bioconda
channel_priority: flexible
cache-downloads: true
cache-environment: true
create-args: >-
python=${{ matrix.python-version }}.*=*_cp*
gromacs==${{ matrix.gromacs-version }}
- name: Python version information ${{ matrix.python-version }}
run: |
python -c "import sys; print(sys.version)"
- name: micromamba environment information
run: |
micromamba info
micromamba list
cat /proc/cpuinfo || (/usr/sbin/system_profiler SPHardwareDataType; /usr/sbin/sysctl -a | grep machdep.cpu)
micromamba list | grep python | grep ${{ matrix.python-version }}
- name: Install package (with no dependencies)
run: |
python -m pip install --no-deps -e .
- name: Run tests
run: >-
pytest -v
--disable-pytest-warnings
--durations=20
--low-performance
--cov-config=pyproject.toml
--cov="./gromacs"
--cov-report=xml
--cov-report=term
--color=yes
./tests
- name: Coverage report
run: |
coverage report --show-missing
- name: Codecov
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
name: codecov-${{ matrix.os }}-py${{ matrix.python-version }}
files: ./coverage.xml
fail_ci_if_error: false