Compare commits
11 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 70f11ba258 | |||
| 2dbc1693c5 | |||
| ff15575473 | |||
| 67b6944c39 | |||
| c937d8e0d7 | |||
| d4d835fd31 | |||
| 3f0d6d8e29 | |||
| 6c44f1415e | |||
| c28d9be4b0 | |||
| 77cd910b67 | |||
| b460c5cca3 |
@@ -4,40 +4,24 @@ on:
|
||||
pull_request:
|
||||
push:
|
||||
branches: [main]
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
lint:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: "3.12"
|
||||
cache: pip
|
||||
- run: pip install -r requirements.txt
|
||||
- run: ruff check .
|
||||
- run: ls -la "$GITEA_WORKSPACE" && pip install ruff==6.* && (cd "$GITEA_WORKSPACE" && ruff check .)
|
||||
|
||||
test:
|
||||
needs: lint
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: "3.12"
|
||||
cache: pip
|
||||
- run: pip install -r requirements.txt
|
||||
- run: pytest -q --cov=app --cov-branch --cov-fail-under=60
|
||||
- run: pip install -r "$GITEA_WORKSPACE/requirements.txt" pytest pytest-cov
|
||||
- run: cd "$GITEA_WORKSPACE" && pytest -q --cov=app --cov-branch --cov-fail-under=60
|
||||
|
||||
metrics:
|
||||
needs: test
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: "3.12"
|
||||
cache: pip
|
||||
- run: pip install -r requirements.txt
|
||||
- run: radon cc app -s -a
|
||||
- run: xenon --max-absolute C app/
|
||||
- run: pip install radon xenon
|
||||
- run: cd "$GITEA_WORKSPACE" && radon cc app -s -a && xenon --max-absolute C app/
|
||||
|
||||
Reference in New Issue
Block a user