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
|
name: Build-Test-Multi-Scipy-Numpy
on:
push:
branches: [release]
pull_request:
branches: [master, release]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
numpy: ['2.0.1'] #['1.16.5', '1.18.5', '1.20.3', '1.22.4', '1.24.4', '1.26.4', '2.0.1']
scipy: ['1.14.0'] #['1.7.3', '1.8.1', '1.9.3', '1.10.1', '1.12.0', '1.14.0']
python-version: ['3.10'] #['3.7', '3.8', '3.9', '3.10']
os: [ubuntu-latest]
architecture: ['x64']
include:
- numpy: '1.16.5'
scipy: '1.7.3'
python-version: '3.7'
- numpy: '1.18.5'
scipy: '1.7.3'
python-version: '3.7'
- numpy: '1.18.5'
scipy: '1.8.1'
python-version: '3.8'
- numpy: '1.18.5'
scipy: '1.9.3'
python-version: '3.8'
- numpy: '1.20.3'
scipy: '1.7.3'
python-version: '3.7'
- numpy: '1.20.3'
scipy: '1.7.3'
python-version: '3.8'
- numpy: '1.20.3'
scipy: '1.8.1'
python-version: '3.8'
- numpy: '1.20.3'
scipy: '1.9.3'
python-version: '3.8'
- numpy: '1.20.3'
scipy: '1.10.1'
python-version: '3.8'
- numpy: '1.22.4'
scipy: '1.7.3'
python-version: '3.8'
- numpy: '1.22.4'
scipy: '1.9.3'
python-version: '3.8'
- numpy: '1.22.4'
scipy: '1.10.1'
python-version: '3.8'
- numpy: '1.24.4'
scipy: '1.8.1'
python-version: '3.8'
- numpy: '1.24.4'
scipy: '1.9.3'
python-version: '3.10'
- numpy: '1.24.4'
scipy: '1.10.1'
python-version: '3.8'
- numpy: '1.24.4'
scipy: '1.12.0'
python-version: '3.9'
- numpy: '1.26.4'
scipy: '1.10.1'
python-version: '3.9'
- numpy: '1.26.4'
scipy: '1.12.0'
python-version: '3.9'
- numpy: '1.26.4'
scipy: '1.14.0'
python-version: '3.10'
- numpy: '2.0.1'
scipy: '1.14.0'
python-version: '3.10'
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }} ${{ matrix.architecture }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
architecture: ${{ matrix.architecture }}
- name: cache Linux
uses: actions/cache@v4
if: startsWith(runner.os, 'Linux')
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements_test.txt') }}
restore-keys: |
${{ runner.os }}-${{ runner.architecture }}-${{ runner.python-version }}pip-
- name: Install Ubuntu dependencies
if: startsWith(runner.os, 'Linux')
run: |
# Taken from scipy
sudo apt-get update
sudo apt-get install -y libopenblas-dev libatlas-base-dev liblapack-dev gfortran libgmp-dev libmpfr-dev libsuitesparse-dev ccache libmpc-dev
- name: Install dependencies
run: |
python -c "import platform; print(platform.platform()); print(platform.architecture())"
python -m pip install --upgrade pip
python -m pip install wheel
pip install -r requirements_test.txt
pip install numpy==${{ matrix.numpy }} scipy==${{ matrix.scipy }}
- name: Add numba
if: ${{ matrix.python-version == '3.6' || matrix.python-version == '3.7' || matrix.python-version == '3.8' || matrix.python-version == '3.9' || matrix.python-version == '3.10' || matrix.python-version == '3.11' || matrix.python-version == '3.12' }}
run: |
pip install numba
- name: Test with pytest
run: |
pytest . -v --cov-report html --cov=fluids --cov-report term-missing -m "not online and not thermo and not numba"
coveralls
env:
COVERALLS_REPO_TOKEN: ${{ secrets.coveralls }}
COVERALLS_PARALLEL: true
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
finish:
needs: build
runs-on: ubuntu-latest
steps:
- name: Coveralls Finished
env:
COVERALLS_REPO_TOKEN: ${{ secrets.coveralls }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
curl https://coveralls.io/webhook?repo_token=${{ secrets.coveralls }} -d "payload[build_num]=${{ github.sha }}&payload[status]=done"
|