-
-
Notifications
You must be signed in to change notification settings - Fork 1
42 lines (39 loc) · 1.05 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
name: Tests and checks
on:
pull_request:
branches:
- main
push:
branches:
- main
permissions:
checks: write
jobs:
run-tests:
runs-on: ubuntu-22.04
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Create Virtual Environment
run: |
python3 -m venv venv
source venv/bin/activate
- name: Install dependencies
run: |
pip install -r requirements-test.txt
- name: Run unit tests for fk.core
run: |
PYTHONPATH=src:tests coverage run -m xmlrunner -o test-results discover -v fk.tests
- name: Publish test report
uses: mikepenz/action-junit-report@v4
with:
report_paths: 'test-results/TEST-*.xml'
include_passed: true
- name: Upload code coverage to coveralls.io
run: coveralls --service=github
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}