Skip to content

Maybe we do need quotes around these... #327

Maybe we do need quotes around these...

Maybe we do need quotes around these... #327

Workflow file for this run

name: CI
on:
push:
pull_request:
schedule:
# run every Wednesday at 5pm UTC
- cron: '17 0 * * 3'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
tests:
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- name: Code style checks
os: ubuntu-latest
python: 3.x
toxenv: codestyle
- name: Python 3.12 with astropy data and coverage
os: ubuntu-latest
python: '3.12'
toxenv: py312-test-cov
toxargs: -v
toxposargs: --remote-data=astropy
- name: Python 3.12 (Windows)
os: windows-latest
python: '3.12'
toxenv: py312-test
- name: Python 3.12 (MacOS X)
os: macos-latest
python: '3.12'
toxenv: py312-test
- name: Python 3.11
os: ubuntu-laters
python: '3.11'
toxenv: py311-test
- name: Python 3.10
os: ubuntu-latest
python: '3.10'
toxenv: py310-test
- name: Python 3.9
os: ubuntu-latest
python: 3.9
toxenv: py39-test
- name: Python 3.8 with oldest supported version of key dependencies
os: ubuntu-20.04
python: 3.8
toxenv: py38-test-oldestdeps
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- name: Install language-pack-de and tzdata
if: startsWith(matrix.os, 'ubuntu')
run: |
sudo apt-get update
sudo apt-get install language-pack-de tzdata graphviz
- name: Install Python dependencies
run: python -m pip install --upgrade tox codecov
- name: Run tests
run: tox ${{ matrix.toxargs }} -e ${{ matrix.toxenv }} -- ${{ matrix.toxposargs }}
# TODO: Do we need --gcov-glob "*cextern*" ?
- name: Upload coverage to codecov
if: ${{ contains(matrix.toxenv,'-cov') }}
uses: codecov/codecov-action@v3
with:
file: ./coverage.xml
allowed_failures:
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- name: (Allowed Failure) Python 3.12 with remote data and dev version of key dependencies
os: ubuntu-latest
python: '3.12-dev'
toxenv: py312-test-devdeps
toxposargs: --remote-data=any
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- name: Install language-pack-de and tzdata
if: startsWith(matrix.os, 'ubuntu')
run: |
sudo apt-get update
sudo apt-get install language-pack-de tzdata
- name: Install Python dependencies
run: python -m pip install --upgrade tox codecov
- name: Run tests
run: tox ${{ matrix.toxargs }} -e ${{ matrix.toxenv }} -- ${{ matrix.toxposargs }}