Files
webssh/.github/workflows/python.yml
2025-07-27 18:46:27 +08:00

36 lines
956 B
YAML

# https://beta.ruff.rs
name: python
on:
push:
branches: [master]
pull_request:
branches: [master]
jobs:
ruff:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: pip install --user ruff
- run: ruff --format=github --ignore=F401 --target-version=py38 .
pytest:
strategy:
fail-fast: false
matrix:
python-version: ["3.10", "3.11", "3.12"]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- run: pip install pytest==8.1.2 pytest-cov -r requirements.txt
- run: pytest --cov=webssh
- run: mkdir -p coverage
- uses: tj-actions/coverage-badge-py@v2
with:
output: coverage/coverage.svg
- uses: JamesIves/github-pages-deploy-action@v4
with:
branch: coverage-badge
folder: coverage