-
Notifications
You must be signed in to change notification settings - Fork 20
120 lines (109 loc) · 3.6 KB
/
test-python-package-with-conda.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
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
name: Test mahotas-imread
on: [push]
jobs:
build-linux:
runs-on: ubuntu-latest
strategy:
matrix:
python-version:
- '3.7'
- '3.8'
- '3.9'
- '3.10'
- '3.11'
- '3.12'
numpy-version:
- '1.19'
- '1.20'
- '1.21'
- '1.22'
- '1.23'
- '1.24'
- '1.25'
- '1.26'
- '2.0'
exclude:
# 3.7 is too old for NumPy 1.22+
- python-version: '3.7'
numpy-version: '1.22'
- python-version: '3.7'
numpy-version: '1.23'
- python-version: '3.7'
numpy-version: '1.24'
- python-version: '3.7'
numpy-version: '1.25'
- python-version: '3.7'
numpy-version: '1.26'
- python-version: '3.7'
numpy-version: '2.0'
# 3.8 is too old for NumPy 1.25+
- python-version: '3.8'
numpy-version: '1.25'
- python-version: '3.8'
numpy-version: '1.26'
- python-version: '3.8'
numpy-version: '2.0'
# NumPy 1.20 & Python 3.7 trigger a bad resolve from mamba
- python-version: '3.7'
numpy-version: '1.20'
# NumPy 1.19 is not available on 3.7-9
- python-version: '3.7'
numpy-version: '1.19'
- python-version: '3.8'
numpy-version: '1.19'
- python-version: '3.9'
numpy-version: '1.19'
# NumPy <1.21 are too old for Python 3.10
- python-version: '3.10'
numpy-version: '1.19'
- python-version: '3.10'
numpy-version: '1.20'
# NumPy <1.23 are too old for Python 3.11
- python-version: '3.11'
numpy-version: '1.19'
- python-version: '3.11'
numpy-version: '1.20'
- python-version: '3.11'
numpy-version: '1.21'
- python-version: '3.11'
numpy-version: '1.22'
# NumPy <=1.25 are too old for Python 3.12
- python-version: '3.12'
numpy-version: '1.19'
- python-version: '3.12'
numpy-version: '1.20'
- python-version: '3.12'
numpy-version: '1.21'
- python-version: '3.12'
numpy-version: '1.22'
- python-version: '3.12'
numpy-version: '1.23'
- python-version: '3.12'
numpy-version: '1.24'
- python-version: '3.12'
numpy-version: '1.25'
steps:
- uses: actions/checkout@v4
- uses: conda-incubator/setup-miniconda@v2
with:
activate-environment: imread_test_env
python-version: ${{ matrix.python-version }}
auto-activate-base: false
- name: Add conda to system path
run: |
# $CONDA is an environment variable pointing to the root of the miniconda directory
echo $CONDA/bin >> $GITHUB_PATH
- name: Install dependencies
run: |
conda install --name imread_test_env python=${{ matrix.python-version }} numpy=${{ matrix.numpy-version }}
conda install --quiet --yes -n imread_test_env jpeg libpng libwebp libtiff gcc_linux-64 gxx_linux-64 coveralls pytest
- name: Build
shell: bash -l {0}
run: |
conda activate imread_test_env
make debug
- name: Test with pytest
shell: bash -l {0}
run: |
conda activate imread_test_env
python -m pytest -v