IDEA plugin not generating correct module dependencies

I have, among other things, the following in my ‘buildSrc/build.gradle’ file:

dependencies {

compile “netflix:odin:latest.release”

compile ‘com.google.guava:guava:14.+’

compile gradleApi()

testCompile ‘junit:junit:4.11’

testCompile “netflix:junit-util:1+”

testCompile ‘org.hamcrest:hamcrest-core:1.3’

testCompile ‘org.hamcrest:hamcrest-library:1.3’

testCompile ‘xml-apis:xml-apis:1.4.01’

testCompile ‘xmlunit:xmlunit:1.3’

integrationTestCompile configurations.testCompile

integrationTestCompile sourceSets.main.output

integrationTestCompile sourceSets.test.output }

‘gradlew test’ works fine from the command line.

When I import the ‘buildSrc.iml’ file generated from performing ‘gradlew idea’, I need to do two other things before being able to run tests in IDEA: * delete ‘groovy-all-2.0.7.jar’ from the module’s dependencies * delete ‘xml-apis-2.0.2.jar’ from the module’s dependencies * add ‘xml-apis-1.4.01.jar’ to the module’s dependencies

This sounds like a bug in the IDEA plugin (since running gradle from the command line works fine).