Skip to content

Commit

Permalink
Actually run jacoco during check but only on linux
Browse files Browse the repository at this point in the history
Signed-off-by: Daniel Widdis <[email protected]>
  • Loading branch information
dbwiddis committed Aug 16, 2023
1 parent b6d8f2b commit b732fa9
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
4 changes: 1 addition & 3 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,7 @@ jobs:
run: |
./gradlew check
- name: Upload Coverage Report
if: |
${{ matrix.os == 'ubuntu-latest'
&& success() }}
if: matrix.os == 'ubuntu-latest'
uses: codecov/codecov-action@v3
with:
file: ./build/reports/jacoco/test/jacocoTestReport.xml
9 changes: 9 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ validateNebulaPom.enabled = false
buildscript {
ext {
opensearch_version = System.getProperty("opensearch.version", "3.0.0-SNAPSHOT")
System.setProperty('tests.security.manager', 'false')
}

repositories {
Expand Down Expand Up @@ -131,6 +132,14 @@ test {
include '**/*Tests.class'
}

jacocoTestReport {
dependsOn test
reports {
xml.required = true
}
}
tasks.named("check").configure { dependsOn(jacocoTestReport) }

task integTest(type: RestIntegTestTask) {
description = "Run tests against a cluster"
testClassesDirs = sourceSets.test.output.classesDirs
Expand Down

0 comments on commit b732fa9

Please sign in to comment.