Is anyone using Spock for their integration tests? I’ve had the integTest task working for quite some time with standard JUnit-based integration tests. Today, I tried to add my first Spock-based integration test (already been using it for unit tests for a while).
In my build script, I changed this:
sourceSets {
integTest {
java {
srcDir 'src/testIntegration/java'
}
...
}
...
}
to this:
sourceSets {
integTest {
java {
srcDir 'src/testIntegration/java'
srcDir 'src/testIntegration/groovy'
}
...
}
...
}
My integTest task already uses this for the include, so I do not think I need to change it:
include( '**/*IntegrationTest*' )
The integration test source file in the the proper location, but it never gets compiled. Actually, running with --debug shows that Gradle does not think there are any source files for compileIntegTestGroovy to build. I’m at a loss as to why that is.
I guess I’m looking for someone else to tell me they are successfully doing this, so I know I’m doing something silly on my side.
Thanks,
Jamie