Replace pytest-httpbin with minimal Falcon version (#160) #144
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: "CI/CD" | |
on: | |
pull_request: | |
push: | |
branches: | |
- master | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: ${{ github.event_name == 'pull_request' }} | |
jobs: | |
lint: | |
name: lint | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Setup Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.12' | |
cache: 'pip' | |
- name: Install hatch | |
run: pipx install hatch | |
- name: Lint | |
run: hatch run lint | |
docs: | |
name: build docs | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Setup Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.12' | |
cache: 'pip' | |
- name: Install hatch | |
run: pipx install hatch | |
- name: Build docs | |
run: hatch run docs:build --fail-on-warning | |
build: | |
name: build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Setup Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.13' | |
cache: 'pip' | |
- name: Install hatch | |
run: pipx install hatch | |
- name: Install twine | |
run: pipx install twine | |
- name: Build distribution | |
run: hatch build | |
- name: Check build | |
run: twine check --strict dist/* | |
test: | |
name: test on ${{ matrix.py }} | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
py: | |
- 'pypy3.10' | |
- '3.13' | |
- '3.12' | |
- '3.11' | |
- '3.10' | |
- '3.9' | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Setup Python for test ${{ matrix.py }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.py }} | |
cache: pip | |
- name: Install hatch | |
run: pipx install hatch | |
- name: Run test suite | |
run: hatch run test.${{ !startsWith(matrix.py, 'pypy') && 'py' || '' }}${{ matrix.py }}:test |