Skip to content

Commit b2e84ec

Browse files
committed
JaCoCo + build on Mac OS as well
1 parent de37b48 commit b2e84ec

File tree

3 files changed

+9
-5
lines changed

3 files changed

+9
-5
lines changed

.github/workflows/gradle.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
runs-on: ${{ matrix.os }}
2424
strategy:
2525
matrix:
26-
os: [ ubuntu-latest, windows-latest ]
26+
os: [ ubuntu-latest, windows-latest, macos-latest ]
2727
permissions:
2828
contents: read
2929

.github/workflows/sonar.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,15 @@
1-
name: SonarCloud
1+
name: Java build with Gradle and SonarCloud
22
on:
33
push:
44
branches:
55
- main
66
pull_request:
7-
types: [ opened, synchronize, reopened ]
7+
types:
8+
- opened
9+
- synchronize
10+
- reopened
11+
branches:
12+
- main
813
jobs:
914
build:
1015
name: Build and analyze
@@ -34,4 +39,4 @@ jobs:
3439
env:
3540
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
3641
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
37-
run: ./gradlew build sonar --info
42+
run: ./gradlew build jacocoTestReport sonar --info

build.gradle.kts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@ tasks.withType<Test> {
5959
}
6060

6161
tasks.jacocoTestReport {
62-
dependsOn(tasks.test) // tests are required to run before generating the report
6362
reports {
6463
xml.required = true
6564
}

0 commit comments

Comments
 (0)