Quantcast
Channel: JetBrains Developer Community : Thread List - IntelliJ IDEA Users
Viewing all articles
Browse latest Browse all 5661

Unable to debug a Gradle/Groovy project.

$
0
0

I'm using Gradle to build a Groovy project and I'm unable to configure either Gradle or InteilliJ IDEA appropriately to allow me to debug the project. I've created a barebones project exhibiting the behavior when running a simple test case.

 

My project builds and tests execute successfully, but if I set a breakpoint in either of the 2 lines of executable code and use the settings below for remote debug, it doesn't work. IDEA connects successfully but never stops execution.

 

Please help.

 

The example code is at https://github.com/clstokes/gradle-groovy-debug-test.

 

My gradle environment is:

------------------------------------------------------------
Gradle 1.2
------------------------------------------------------------

Gradle build time: Wednesday, September 12, 2012 10:46:02 AM UTC
Groovy: 1.8.6
Ant: Apache Ant(TM) version 1.8.4 compiled on May 22 2012
Ivy: 2.2.0
JVM: 1.7.0-u10-b09 (Oracle Corporation 23.6-b03)
OS: Mac OS X 10.8.2 x86_64

 

My build.gradle looks like this:

 

apply plugin: 'idea'
apply plugin: 'groovy'

repositories {
  mavenLocal()  mavenCentral()
}

dependencies {
  groovy(      "org.codehaus.groovy:groovy:2.0.5"  )  testCompile(      "org.testng:testng:6.8"  )
}

test {
  useTestNG()
}

 

I set GRADLE_OPTS as the following:

 

export GRADLE_OPTS="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005"

 

And my debug configuration in IDEA looks like this:

2012-10-30_1923.png


Viewing all articles
Browse latest Browse all 5661

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>