Skip to content

Commit

Permalink
More Readable Gradle test config. (#18890)
Browse files Browse the repository at this point in the history
The integration testing logs are extremely noisy today. The logs contain the entire test STDOUT and are a pain to read.

This PR contains a better test setup config to reduce logging output.

The main change is to comment out ShowStandardStreams in the integration tests plugin.
Then we add the started event so Gradle shows us when a test is started. Some tests take a longer time. It is useful to know they have begun so it's clear if the job is stuck or not.
Standardise the above setting across all of our custom test tasks.
  • Loading branch information
davinchia authored Nov 3, 2022
1 parent 188612c commit 64736f0
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 6 deletions.
15 changes: 11 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -357,8 +357,9 @@ subprojects { subproj ->
excludeTags(integrationTagName, slowIntegrationTagName, cloudStorageTestTagName)
}
testLogging() {
events 'failed'
events "passed", "skipped", "failed"
exceptionFormat 'full'
// uncomment to get the full log output
// showStandardStreams = true
}
finalizedBy jacocoTestReport
Expand All @@ -369,8 +370,10 @@ subprojects { subproj ->
includeTags integrationTagName
}
testLogging() {
events 'failed'
events "passed", "failed", "started"
exceptionFormat 'full'
// uncomment to get the full log output
// showStandardStreams = true
}
finalizedBy jacocoTestReport
}
Expand All @@ -380,17 +383,21 @@ subprojects { subproj ->
includeTags slowIntegrationTagName
}
testLogging() {
events 'failed'
events "passed", "failed", "started"
exceptionFormat 'full'
// uncomment to get the full log output
// showStandardStreams = true
}
finalizedBy jacocoTestReport
}

task allTests(type: Test) {
useJUnitPlatform()
testLogging() {
events 'failed'
events "passed", "failed", "started"
exceptionFormat 'full'
// uncomment to get the full log output
// showStandardStreams = true
}
finalizedBy jacocoTestReport
}
Expand Down
5 changes: 3 additions & 2 deletions buildSrc/src/main/groovy/airbyte-integration-test-java.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,10 @@ class AirbyteIntegrationTestJavaPlugin implements Plugin<Project> {
}

testLogging() {
events "passed", "failed"
events "passed", "failed", "started"
exceptionFormat "full"
showStandardStreams = true
// uncomment to get the full log output
// showStandardStreams = true
}

outputs.upToDateWhen { false }
Expand Down

0 comments on commit 64736f0

Please sign in to comment.