File tree 3 files changed +46
-2
lines changed
3 files changed +46
-2
lines changed Original file line number Diff line number Diff line change
1
+ name : Run tests and upload coverage
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - main
7
+ - develop
8
+ pull_request :
9
+ branches :
10
+ - develop
11
+
12
+ jobs :
13
+ test :
14
+ name : Run tests and collect coverage
15
+ runs-on : ubuntu-latest
16
+ steps :
17
+ - name : Checkout code
18
+ uses : actions/checkout@v4
19
+ with :
20
+ fetch-depth : 0
21
+
22
+ - name : Set up Python
23
+ uses : actions/setup-python@v4
24
+ with :
25
+ python-version : ' 3.x' # Specify your Python version if necessary
26
+
27
+ - name : Install dependencies
28
+ run : |
29
+ pip install -r requirements.txt
30
+ pip install pytest pytest-cov
31
+
32
+ - name : Run tests with coverage
33
+ run : pytest --cov=dracan --cov-report=xml
34
+
35
+ - name : Upload coverage to Codecov
36
+ uses : codecov/codecov-action@v4
37
+ with :
38
+ token : ${{ secrets.CODECOV_TOKEN }}
39
+ files : ./coverage.xml
40
+ flags : unittests
41
+ name : codecov-coverage
42
+ fail_ci_if_error : true # Ensures the action fails if there’s an issue with uploading
Original file line number Diff line number Diff line change 1
- # Use the official Python 3.14.0 slim image
1
+ # Use the official Python alpine image
2
2
FROM python:alpine
3
3
4
4
# Set environment variables for production
Original file line number Diff line number Diff line change 2
2
<img src =" https://veinar.pl/dracan.png " alt =" logo " width =" 300 " />
3
3
4
4
![ GitHub License] ( https://img.shields.io/github/license/Veinar/dracan?style=flat )
5
- ![ Contrib Welcome] ( https://img.shields.io/badge/contributions-welcome-blue )
6
5
![ Code style] ( https://img.shields.io/badge/code%20style-black-black )
6
+ ![ Docker Image Size] ( https://img.shields.io/docker/image-size/veinar/dracan )
7
+ ![ Docker Pulls] ( https://img.shields.io/docker/pulls/veinar/dracan?color=yellow )
8
+ ![ Contrib Welcome] ( https://img.shields.io/badge/contributions-welcome-blue )
7
9
8
10
<br >
9
11
</p >
You can’t perform that action at this time.
0 commit comments