-
-
Save daltonjorge/4c5da848111f7c37d5f89eb66145bdb4 to your computer and use it in GitHub Desktop.
Print Gradle test results to console
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
/* | |
Sample output: | |
> gradle test ruby-1.9.3-p194 testing_with_gradle 9179829 ✗ | |
... | |
:test | |
Results: SUCCESS (84 tests, 74 successes, 0 failures, 10 skipped) | |
*/ | |
test { | |
testLogging { | |
afterSuite { desc, result -> | |
if (!desc.parent) { // will match the outermost suite | |
println "Results: ${result.resultType} (${result.testCount} tests, ${result.successfulTestCount} successes, ${result.failedTestCount} failures, ${result.skippedTestCount} skipped)" | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment