ENH: Only test on Py3.10 for version branches #112
Workflow file for this run
This file contains 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
name: Version Branch CI/CD | |
on: | |
pull_request: | |
branches: ["v*"] | |
jobs: | |
pre-commit: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4.1.6 | |
- uses: actions/setup-python@v5.1.0 | |
with: | |
python-version: 3.10.14 | |
- name: Install pre-commit | |
run: pip install pre-commit | |
- name: Run pre-commit | |
run: pre-commit run --all-files | |
pytest: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out repository | |
uses: actions/checkout@v4.1.6 | |
with: | |
fetch-depth: 0 | |
- name: Install the latest version of rye | |
uses: eifinger/setup-rye@v3.0.2 | |
- name: Setup the environment | |
run: rye sync --all-features | |
- name: Test with pytest | |
run: rye run pytest --cov=epochalyst --cov-branch --cov-fail-under=95 tests | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4.1.6 | |
- name: Install the latest version of rye | |
uses: eifinger/setup-rye@v3.0.2 | |
- name: Build the package | |
run: rye build | |
- uses: actions/upload-artifact@v4.3.3 | |
with: | |
path: ./dist |