-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
67 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time | ||
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-maven | ||
|
||
# This workflow uses actions that are not certified by GitHub. | ||
# They are provided by a third-party and are governed by | ||
# separate terms of service, privacy policy, and support | ||
# documentation. | ||
|
||
name: Java CI | ||
|
||
on: | ||
push: | ||
branches: [ "master" ] | ||
pull_request: | ||
branches: [ "master" ] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Set up JDK 17 | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: '17' | ||
distribution: 'temurin' | ||
cache: maven | ||
- name: Build & test with Maven | ||
run: mvn clean test | ||
|
||
sonarcloud: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
# Disabling shallow clone is recommended for improving relevancy of reporting | ||
fetch-depth: 0 | ||
- name: SonarCloud Scan | ||
uses: sonarsource/sonarcloud-github-action@master | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
sonar.projectKey=plume-showcase | ||
sonar.projectName=plume-showcase | ||
sonar.projectVersion=1.0 | ||
sonar.sourceEncoding=UTF-8 | ||
sonar.sources=src | ||
|
||
# Java | ||
# sonar.java.binaries=/usr/local/java/jdk-17/bin/ | ||
sonar.exclusions=src/main/java/com/coreoz/db/generated/*,\ | ||
src/main/java/com/coreoz/db/QuerydslGenerator.java | ||
|
||
# Configure Lombok if needed | ||
# sonar.java.libraries=/home/coreoz/lombok-1.18.30.jar | ||
|
||
#Tests | ||
# Disable some rules on some files | ||
sonar.issue.ignore.multicriteria=j1,j2 | ||
#No literal duplication tests | ||
sonar.issue.ignore.multicriteria.j1.ruleKey=squid:S1192 | ||
sonar.issue.ignore.multicriteria.j1.resourceKey=src/test/**/* | ||
#No method name compliance for tests | ||
sonar.issue.ignore.multicriteria.j2.ruleKey=squid:S00100 | ||
sonar.issue.ignore.multicriteria.j2.resourceKey=src/test/**/* |