println project.sourceSets.main.compileClasspath.class

        -> class 
org.gradle.api.internal.artifacts.configurations.DefaultConfiguration_Decorated

println project.sourceSets.test.compileClasspath.class

        -> class org.gradle.api.internal.file.PathResolvingFileCollection


Why would the compileClasspath types be different across the main vs. test 
source sets for the same project?

this type discrepancy keeps me from doing something like the following:

        
[project.sourceSets.main,project.sourceSets.test]*.compileClasspath.allDependencies.each
 { dep ->
                // do interesting things with $dep
        }

attempting to do this fails with the following error:

        * What went wrong:
        A problem occurred evaluating root project 'myproject'.
        Cause: No such property: allDependencies for class: 
org.gradle.api.internal.file.PathResolvingFileCollection

the error makes sense to me, but it doesn't make sense why the test source set 
is of type PathResolvingFileCollection as opposed to main being of type 
DefaultConfiguration.

- C

Reply via email to