-
Notifications
You must be signed in to change notification settings - Fork 12
31 lines (29 loc) · 923 Bytes
/
test.yml
File metadata and controls
31 lines (29 loc) · 923 Bytes
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
name: Test
on: [pull_request]
jobs:
test:
name: Unit Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
# fetching all history (to help sonar computing PRs)
fetch-depth: 0
- name: Set up JDK 17
uses: actions/setup-java@v1
with:
java-version: 17
- name: Start Minikube
run: minikube start
- name: Create test namespace
run: kubectl create ns gaia-runner
- name: Run Maven tests
run: mvn --batch-mode org.jacoco:jacoco-maven-plugin:prepare-agent verify org.jacoco:jacoco-maven-plugin:report
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Sonar Analysis
if: ${{ github.actor != 'dependabot[bot]' }}
run: mvn sonar:sonar
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}