I’m seeing IntelliJ v13 incorrectly marking directories like src/intTest/java as “main” source roots when they had been marked as “test source” roots. It happens when you open the JetGradle window and refresh the Project.
JetBrains tells me through the issue comments that IDEA v13 does not respect manually configured test source roots across Gradle project refreshes. I don’t think this is the right feature implementation, but changing that is up to them. In the meantime, your project needs this IDEA-specific config to preserve custom test-source roots:
Please take a look at this comment in JetBrains bug tracker - http://youtrack.jetbrains.com/issue/IDEA-117668#comment=27-639821 Change in scopes mapping can help you to add test dependencies to your IDEA project. If you only add source directories to IdeaModule.testSourceDirs IDEA may not be able to resolve some dependencies for your intTest.