CI demo: metrics + Gitea Actions
This commit is contained in:
26
workflows_заготовки/ci-artifacts.yml
Normal file
26
workflows_заготовки/ci-artifacts.yml
Normal file
@@ -0,0 +1,26 @@
|
||||
# Заготовка для акта «Артефакты» (Gitea Actions): скопировать поверх .gitea/workflows/ci.yml
|
||||
# upload-artifact@v3 — максимально совместим с Gitea Actions;
|
||||
# на новых версиях Gitea можно заменить на @v4.
|
||||
name: CI (artifacts)
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
push:
|
||||
branches: [main]
|
||||
|
||||
jobs:
|
||||
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: pytest -q --cov=app --cov-branch --cov-fail-under=60 --cov-report=xml
|
||||
- uses: actions/upload-artifact@v3
|
||||
if: always()
|
||||
with:
|
||||
name: coverage-report
|
||||
path: coverage.xml
|
||||
Reference in New Issue
Block a user