File tree Expand file tree Collapse file tree 2 files changed +68
-94
lines changed
Expand file tree Collapse file tree 2 files changed +68
-94
lines changed Original file line number Diff line number Diff line change 1+ name : CI
2+
3+ on : [push]
4+
5+ jobs :
6+ gitleaks :
7+ runs-on : ubuntu-latest
8+ steps :
9+ - uses : actions/checkout@v5
10+ with :
11+ fetch-depth : 0 # Full history is needed to scan all commits
12+ - uses : jdx/mise-action@v3
13+ with :
14+ cache : true
15+ - run : gitleaks detect --verbose --redact
16+
17+ pytest :
18+ runs-on : ubuntu-latest
19+ steps :
20+ - uses : actions/checkout@v5
21+ - uses : jdx/mise-action@v3
22+ with :
23+ cache : true
24+ - env :
25+ SECRET_KEY : " ${{ secrets.SECRET_KEY_FOR_TESTS }}"
26+ run : make test
27+
28+ ruff :
29+ runs-on : ubuntu-latest
30+ steps :
31+ - uses : actions/checkout@v5
32+ - uses : jdx/mise-action@v3
33+ with :
34+ cache : true
35+ - run : make lint
36+
37+ coverage :
38+ needs : [pytest]
39+ runs-on : ubuntu-latest
40+ if : github.ref == 'refs/heads/main'
41+ outputs :
42+ badge_url : ${{ steps.upload-coverage-badge-artifact-step.outputs.artifact-url }}
43+ html_report_url : ${{ steps.upload-html-report-artifact-step.outputs.artifact-url }}
44+ steps :
45+ - uses : actions/checkout@v5
46+ - uses : jdx/mise-action@v3
47+ with :
48+ cache : true
49+ - env :
50+ SECRET_KEY : " ${{ secrets.SECRET_KEY_FOR_TESTS }}"
51+ COVERAGE_THRESHOLD : 80
52+ run : make test-coverage
53+ - uses : actions/upload-artifact@v4
54+ id : upload-html-report-artifact-step
55+ if : always()
56+ with :
57+ name : coverage-html
58+ path : htmlcov
59+ retention-days : 10
60+ compression-level : 0
61+ - uses : actions/upload-artifact@v4
62+ id : upload-coverage-badge-artifact-step
63+ if : always()
64+ with :
65+ name : coverage-badge
66+ path : coverage.svg
67+ retention-days : 10
68+ compression-level : 0
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments