-
Notifications
You must be signed in to change notification settings - Fork 4
40 lines (40 loc) · 1.37 KB
/
code-quality.yml
File metadata and controls
40 lines (40 loc) · 1.37 KB
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
name: "Check code format and quality"
on:
push:
branches: [develop, main]
pull_request:
types: [opened, ready_for_review, synchronize, reopened]
jobs:
check-code-quality:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Check text files format
run: |
build/automation/etc/githooks/scripts/editorconfig-pre-commit.sh
- name: Check Python files format
run: |
make python-linting
- name: Python Dead Code Check
run: |
make tester-build python-dead-code-scanning
- name: Create coverage report
run: |
make coverage-report
- uses: sonarsource/sonarcloud-github-action@master
# SEE: https://github.com/SonarSource/sonarcloud-github-action
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
with:
projectBaseDir: .
args: >
-Dsonar.sources=application,deployment,infrastructure
-Dsonar.organization=nhsd-exeter
-Dsonar.projectKey=uec-dos-int
-Dsonar.coverage.exclusions=tests/**,**/tests/**,deployment,infrastructure
-Dsonar.python.coverage.reportPaths=coverage.xml
-Dsonar.python.version=3.9
-Dsonar.exclusions=application/**/tests/**