mirror of
https://github.com/spring-projects/spring-security.git
synced 2025-07-19 16:53:31 +00:00
Added project property to enable test coverage.
This commit is contained in:
parent
2c219f7a66
commit
5fe589e360
@ -29,6 +29,7 @@ task emmaInstrument {
|
||||
|
||||
// Modify test tasks in the project to generate coverage data
|
||||
afterEvaluate {
|
||||
if (project.hasProperty('coverage') && ['on','true'].contains(project.properties.coverage)) {
|
||||
tasks.withType(Test.class).each { task ->
|
||||
task.dependsOn emmaInstrument
|
||||
task.configure() {
|
||||
@ -39,6 +40,7 @@ afterEvaluate {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (rootProject.getTasksByName('coverageReport', false).isEmpty()) {
|
||||
rootProject.task('coverageReport') << {
|
||||
|
Loading…
x
Reference in New Issue
Block a user