Skip to content

MOAR Improvements: Cross-OS testing, .gitignore updates, supporting… #18

MOAR Improvements: Cross-OS testing, .gitignore updates, supporting…

MOAR Improvements: Cross-OS testing, .gitignore updates, supporting… #18

Workflow file for this run

name: Testing
on:
push:
pull_request:
defaults:
run:
shell: /bin/bash --noprofile --norc -Eeuxo pipefail {0}
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- windows-latest
- macos-latest
python-version:
- '3.6'
- '3.7'
- '3.8'
- '3.9'
- '3.10'
- '3.11'
# - '3.12' # FixMe: https://github.com/pylint-dev/pylint-pytest/issues/3
# Just for Python 3.6 which is not available in `ubuntu-latest`.
exclude:
- python-version: '3.6'
os: ubuntu-latest
include:
- python-version: '3.6'
os: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
cache-dependency-path: setup.py
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install tox "tox-gh-actions>=3.0; python_version >= '3.7'" "tox-gh-actions<3.0; python_version < '3.7'"
- name: Modify tox.ini for Python3.6
if: matrix.python-version == '3.6'
run: sed -i '/\[tox\]/a requires = virtualenv<20.22.0' tox.ini
- name: Test with tox
run: tox
- name: Test with tox
if: matrix.python-version == '3.6'
run: tox -vv
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true
files: test_artifacts/cobertura.xml