I have several folders trying to seperate my tests up into unit, integration, 3rd party, db. This way I can have my tests seperated into chunks purposes, to make TDD easier/faster. Here is the task that I am trying to use.
task integrationTest(type: Test) {
testClassesDir = sourceSets.integration.output.classesDir
classpath = sourceSets.integration.runtimeClasspath
maxParallelForks 8
maxHeapSize = "4048m"
}
I know there is testReportDir, but it's deprecated. I want to be able to use the new method.
I have tried the following closures:
reports {
html = file("$buildDir/reports/intTests")
}
reports {
setDestination = file("$buildDir/reports/intTests")
}
reports {
destinationDir = file("$buildDir/reports/intTests")
}
destinationDir = file("$buildDir/reports/intTests")
I think you want
integrationTest.reports.html.destination = file("$buildDir/reports/intTests")
You may want to consult the api docs for TestTaskReports
which shows that the html report is a DirectoryReport
extending ConfigurableReport
and that that provides the destination accessor referred to in the one liner above.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With