Skip to content

Merge pull request #129 from hanjinliu/docs-version #212

Merge pull request #129 from hanjinliu/docs-version

Merge pull request #129 from hanjinliu/docs-version #212

Workflow file for this run

name: tests
on:
push:
branches:
- main
tags:
- "v*" # Push events to matching v*, i.e. v1.0, v20.15.10
pull_request:
branches:
- main
workflow_dispatch:
jobs:
test:
name: ${{ matrix.platform }} (${{ matrix.python-version }})
runs-on: ${{ matrix.platform }}
strategy:
fail-fast: false
matrix:
python-version: ["3.10", "3.11", "3.12"]
platform: [ubuntu-latest, macos-latest, windows-latest]
steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.11.0
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Create virtual environment
env:
BIN: ${{ matrix.os == 'windows-latest' && 'Scripts' || 'bin' }}
run: |
python -m venv .venv
echo "$GITHUB_WORKSPACE/.venv/$BIN" >> $GITHUB_PATH
- uses: tlambert03/setup-qt-libs@v1.5
- name: Install dependencies
run: python -m pip install .[testing]
- name: Build Rust extension
run: maturin develop --release
- name: Test
uses: aganders3/headless-gui@v1
with:
run: python -m pytest --cov=cylindra --cov=cylindra_builtins --cov-report=xml
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4.0.1
with:
token: ${{ secrets.CODECOV_TOKEN }}
slug: hanjinliu/cylindra