-
Notifications
You must be signed in to change notification settings - Fork 2
37 lines (29 loc) · 973 Bytes
/
main.yaml
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
name: Test RADL
on:
push:
branches: ["master"]
pull_request:
branches: ["master"]
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Check out the codebase.
uses: actions/checkout@v4
- name: Set up Python 3.
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install dependencies
run: python -m pip install pycodestyle ply coverage packaging
- name: Check code style
run: pycodestyle --max-line-length=120 --ignore=E402,W504,W605,E722,E741 . --exclude=doc
- name: Unit tests
run: python -m coverage run --source=. -m unittest discover -v -s test -p '*.py'
- name: Generate XML coverage report
run: python -m coverage xml
- name: Report coverage
uses: codacy/codacy-coverage-reporter-action@v1
with:
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
coverage-reports: coverage.xml