-
Notifications
You must be signed in to change notification settings - Fork 1
51 lines (44 loc) · 1.3 KB
/
Copy pathdevelopment.yml
File metadata and controls
51 lines (44 loc) · 1.3 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
41
42
43
44
45
46
47
48
49
50
51
name: Development
on:
push:
branches: [ main ]
paths:
- '**.py'
- '!docs/**'
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0 # Disabling shallow clone for SonarCloud
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: make develop
- name: Code Linting
run: make lint
- name: Code Testing
run: make test-report
- name: SonarQube Scan
if: matrix.python-version == '3.9'
uses: SonarSource/sonarqube-scan-action@v4
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
with:
args: >
-Dsonar.organization=johnbrandborg
-Dsonar.projectKey=johnbrandborg_cruds
-Dsonar.python.coverage.reportPaths=coverage.xml
-Dsonar.python.version=${{ matrix.python-version }}
-Dsonar.sources=src/
-Dsonar.test.exclusions=tests/**
-Dsonar.tests=tests/