Added Python version classifiers #110
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow will use Nox to run tests and lint for the supported Python versions, and upload the test coverage data. | |
name: Build & Test | |
# Do not run this workflow on pull request since this workflow has permission to modify contents. | |
on: | |
push: | |
branches: | |
- main | |
- release/* | |
paths: | |
- "constraint/**" | |
- "tests/**" | |
- "cythonize_build.py" | |
- "noxfile.py" | |
- "pyproject.toml" | |
- ".github/workflows/build-test-python-package.yml" | |
permissions: | |
# deployments permission to deploy GitHub pages website | |
deployments: write | |
# contents permission to update benchmark contents in gh-pages branch | |
contents: write | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 # fetch all history to avoid detached HEAD state when pushing benchmark results | |
- name: Download previous benchmark data | |
uses: actions/cache@v4 | |
with: | |
path: ./cache | |
key: ${{ runner.os }}-benchmark | |
- uses: fjwillemsen/[email protected] | |
- run: | | |
nox -- ${{ runner.os }} | |
- name: Store benchmark result | |
uses: benchmark-action/github-action-benchmark@v1 | |
with: | |
tool: "pytest" | |
output-file-path: .benchmarks/benchmark_${{ runner.os }}_3.13.json | |
external-data-json-path: ./cache/benchmark-data.json | |
fail-on-alert: true | |
# GitHub API token to make a commit comment | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
comment-always: true | |
summary-always: true | |
# alert-comment-cc-users: '@fjwillemsen' mention a GitHub user in the comment | |
- name: Report to Coveralls | |
uses: coverallsapp/github-action@v2 | |
with: | |
file: coverage.xml | |
format: cobertura | |
fail-on-error: false |