Test #164
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test | |
on: | |
push: | |
pull_request: | |
workflow_dispatch: | |
schedule: | |
- cron: 0 0 1 * * # monthly | |
jobs: | |
test: | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
# baseline: | |
# ubuntu-20.04 + python3.8 + gcc-9 | |
# ubuntu-22.04 + python3.10 + gcc-11 | |
- os: ubuntu-20.04 | |
python-version: 3.8 | |
cc: gcc-9 | |
fc: gfortran-9 | |
- os: ubuntu-22.04 | |
python-version: "3.10" | |
cc: gcc-11 | |
fc: gfortran-11 | |
# other python versions | |
- os: ubuntu-20.04 | |
python-version: 3.6 | |
cc: gcc-9 | |
fc: gfortran-9 | |
- os: ubuntu-20.04 | |
python-version: 3.7 | |
cc: gcc-9 | |
fc: gfortran-9 | |
- os: ubuntu-20.04 | |
python-version: 3.9 | |
cc: gcc-9 | |
fc: gfortran-9 | |
- os: ubuntu-22.04 | |
python-version: "3.11" | |
cc: gcc-11 | |
fc: gfortran-11 | |
# other gcc versions | |
- os: ubuntu-20.04 | |
python-version: 3.8 | |
cc: gcc-8 | |
fc: gfortran-8 | |
- os: ubuntu-20.04 | |
python-version: 3.8 | |
cc: gcc-10 | |
fc: gfortran-10 | |
- os: ubuntu-22.04 | |
python-version: "3.10" | |
cc: gcc-12 | |
fc: gfortran-12 | |
- os: ubuntu-22.04 | |
python-version: "3.10" | |
cc: gcc-13 | |
fc: gfortran-13 | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Checkout the repository | |
uses: actions/checkout@v3 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
cache: "pip" | |
cache-dependency-path: | | |
pyproject.toml | |
tox.ini | |
- name: Cache for GRACE | |
uses: actions/cache@v3 | |
with: | |
path: ~/.cache/python-grace | |
key: python-grace-221.2006.0116 | |
restore-keys: | | |
python-grace- | |
- name: Install dependencies (apt) | |
if: runner.os == 'Linux' | |
uses: awalsh128/cache-apt-pkgs-action@v1 | |
with: | |
packages: | | |
${{ matrix.cc == 'gcc-8' && 'g++-8' || '' }} | |
${{ matrix.fc == 'gfortran-8' && 'gfortran-8' || '' }} | |
${{ matrix.cc == 'gcc-13' && 'g++-13' || '' }} | |
${{ matrix.fc == 'gfortran-13' && 'gfortran-13' || '' }} | |
libmotif-dev | |
- name: Install dependencies (pip) | |
run: | | |
pip install --upgrade pip | |
pip install tox tox-gh-actions | |
- name: Run tests | |
run: tox -vvv | |
env: | |
CC: ${{ matrix.cc }} | |
FC: ${{ matrix.fc }} |