-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (38 loc) · 1.32 KB
/
code-quality.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
name: "Check code format and quality"
on:
push:
branches: [main]
pull_request:
types: [opened, synchronize, reopened]
jobs:
check-code-quality:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
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: |
build/automation/etc/githooks/scripts/python-code-pre-commit.sh
- name: Check Terraform files format
run: |
build/automation/etc/githooks/scripts/terraform-format-pre-commit.sh
- name: Create coverage report
run: |
make build-tester coverage PROFILE=local
- 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: ./application/roaddistance
args: >
-Dsonar.organization=nhsd-exeter
-Dsonar.projectKey=uec-dos-rd
-Dsonar.coverage.exclusions=tests/****/*,utilities/*
-Dsonar.python.coverage.reportPaths=coverage.xml
-Dsonar.python.version=3.10.2