Gradle 4.4-rc-3 is now available for testing

Gradle 4.4 RC3 is available for testing; see the release notes.

4.4 (RCs) introduced an issue in one of my projects. I’m getting

/buildSrc/src/main/groovy/Plugin.groovy: 579: [Static type checking] - No such property: junitXml for class: org.gradle.api.reporting.ReportContainer
 @ line 579, column 15.
                 test.reports.junitXml.destination.exists() && test.reports.junitXml.destination.eachFile { it.lastModified = timestamp }

This did not happen with 4.3.1. I’m currently trying to find out the commit that introduced the issue.
I wonder why the message mentions org.gradle.api.reporting.ReportContainer. And why does https://docs.gradle.org/4.4-rc-1/dsl/org.gradle.api.tasks.testing.Test.html#org.gradle.api.tasks.testing.Test:reports list T as the return type instead of TestTaskReports?

I assume it’s related to https://github.com/gradle/gradle/pull/3234
I could not complete the bisect because some of the commits don’t build:

FAILURE: Build failed with an exception.

* Where:
Script '/home/jochen/git/upstream/gradle/gradle/groovyProject.gradle' line: 83

* What went wrong:
A problem occurred evaluating project ':testingJvm'.
> Configuration with name 'testFixturesCompile' not found.

But I could at least narrow it down:

There are only 'skip'ped commits left to test.                                                                
The first bad commit could be any of:
0f3dc33dc6de9b83e230119e37766eb025d1f2e2  
34e373a75843fabf8f3e23bc3727fd006c182922
cf329ca4e2edd2654e817b81f679b1a1914ccb4d
dfecfafa52ca7db2cfdfd4f5e848943dc4384ae9
f5fc35cf30f95974d363e6f40a74529332565fe7

The Test task implements Reporting<TestTaskReports>, so the parameter <T> is bound to TestTaskReports. Do you get the same problem when compiling with Java or is this a Groovy compiler problem?

Thanks @jochenberger for raising this issue. I was able to reproduce it locally and opened an issue to address this before 4.4 GA is released.

1 Like