Skip to content

Merge pull request #4 from lhelwerd/chore/coverage-2.7 #7

Merge pull request #4 from lhelwerd/chore/coverage-2.7

Merge pull request #4 from lhelwerd/chore/coverage-2.7 #7

Workflow file for this run

name: CI
on:
push:
branches: [ "master", "dev" ]
pull_request:
branches: [ "master", "dev" ]
workflow_dispatch:
permissions:
contents: read
concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true
jobs:
tests:
name: Tests (Python ${{ matrix.python-version }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version:
- "3.8"
- "3.9"
- "3.10"
- "3.11"
- "3.12"
- "3.13"
- "3.14"
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Set up Python ${{ matrix.python-version }}
id: setup-python
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Show environment
run: |
python --version
which python
python -c "import sys; print('Executable:', sys.executable)"
- name: Run tests (unittest)
run: |
pip install coverage
make coverage
- name: Coveralls upload
uses: coverallsapp/github-action@v2
if: "${{ success() }}"
with:
github-token: "${{ secrets.GITHUB_TOKEN }}"
flag-name: "python-${{ matrix.python-version }}"
parallel: true
format: cobertura
files: coverage.xml
test-legacy:
name: Tests (Python 2.7 via container)
runs-on: ubuntu-latest
container:
image: python:2.7
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Install package
run: |
pip install --upgrade pip setuptools coverage
pip install .
- name: Run tests (unittest)
run: |
make coverage
- name: Coveralls upload
uses: coverallsapp/github-action@v2
if: "${{ success() }}"
with:
github-token: "${{ secrets.GITHUB_TOKEN }}"
flag-name: "python-2.7"
parallel: true
format: cobertura
files: coverage.xml
- name: Legacy note
run: echo "Python 2.7 run completed (non-blocking)."
summary:
name: Summary
runs-on: ubuntu-latest
needs: [tests, test-legacy]
if: always()
steps:
- name: Aggregate result
run: |
echo "Modern matrix + legacy (2.7) complete. Check job logs for details."
- name: Close parallel Coveralls build
uses: coverallsapp/github-action@v2
if: "${{ success() }}"
with:
github-token: "${{ secrets.GITHUB_TOKEN }}"
parallel-finished: true