Skip to content

fix path

fix path #5

Workflow file for this run

name: main-build
on:
push:
branches:
- master
pull_request:
branches:
- master
permissions:
checks: write
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
# for Sonar
fetch-depth: 0
- name: Set up JDK
uses: actions/setup-java@v3
with:
java-version: 17
architecture: x64
distribution: temurin
cache: maven
- name: Cache SonarCloud packages
uses: actions/cache@v3
with:
path: ~/.sonar/cache
key: ${{ runner.os }}-sonar
restore-keys: ${{ runner.os }}-sonar
- name: Build with Maven and run Sonar
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: mvn -B -"Dgpg.skip" verify jacoco:report org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
- name: Upload Test Report
uses: actions/upload-artifact@v3
if: always() # always run even if the previous step fails
with:
name: junit-test-results
path: 'target/surefire-reports/TEST-*.xml'
retention-days: 1