Skip to content

Unit test smoke test #44

Unit test smoke test

Unit test smoke test #44

Workflow file for this run

# This workflow will run daily at 06:45.
# It will install Python dependencies and run tests with a variety of Python versions.
# See documentation for help debugging smoke test issues:
# https://lincc-ppt.readthedocs.io/en/latest/practices/ci_testing.html#version-culprit
name: Unit test smoke test
on:
schedule:
- cron: 45 6 * * *
workflow_dispatch:
jobs:
build-and-test:
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- name: Linux, Python 3.8
os: ubuntu-latest
python-version: 3.8
toxenv: py38-test
gfortran-version: 9
- name: Linux, Python 3.9
os: ubuntu-22.04
python-version: 3.9
toxenv: py39-test
gfortran-version: 11
- name: Linux, Python 3.11
os: ubuntu-22.04
python-version: "3.11"
toxenv: py311-test
gfortran-version: 11
- name: macOS, Python 3.8
os: macOS-11
python-version: 3.8
toxenv: py38-test
gfortran-version: 10
- name: macOS, Python 3.10, coverage
os: macOS-11
python-version: "3.10"
# Include at least one coverage option for codecov.
toxenv: py310-test-cov
gfortran-version: 11
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- if: runner.os == 'macOS'
name: macOS gfortran
run: |
sudo ln -s /usr/local/bin/gfortran-${{ matrix.gfortran-version }} /usr/local/bin/gfortran
sudo mkdir /usr/local/gfortran
sudo ln -s /usr/local/Cellar/gcc@${{ matrix.gfortran-version }}/*/lib/gcc/${{ matrix.gfortran-version }} /usr/local/gfortran/lib
- if: runner.os == 'Linux'
name: ubuntu gfortran
run: sudo ln -sf /usr/bin/gfortran-${{ matrix.gfortran-version }} /usr/bin/gfortran
- name: Check gfortran version
run: gfortran --version
- name: Install dependencies
run: pip install numpy tox
- name: Run unit tests with pytest
run: |
mkdir ./.tmp
mkdir ./.tmp/${{ matrix.toxenv }}
tox -e ${{ matrix.toxenv }} -- --remote-data