Gradle 4 - replacing deprecated Test::testClassesDir


(Dimitar Dimitrov) #1

When replacing this deprecated method, which shall we prefer:

  testClassesDirs = files(sourceSets.integrationTest.output.classesDir)

or

  testClassesDirs = sourceSets.integrationTest.output

Strictly speaking, the latter will also bring the resources into the classpath. Is that a good thing?


(Sterling Greene) #2

Neither :slight_smile:

testClassesDirs = sourceSets.integrationTest.output.classesDirs

If you used multiple languages for the same source set, they could use separate output directories.


(Dimitar Dimitrov) #3

Would be nice going forward to have the typical replacements mentioned in the deprecated methods javadoc.