Enhance tooling api to ease debugging of tests run via gradle

Tooling api should provide convenient interface for debugging tests executed by gradle.

The only facility available at the moment is to define a ‘debug’ property at the gradle script and use hard-coded port 5005 for remote debugging (http://www.gradle.org/docs/current/dsl/org.gradle.api.tasks.testing.Test.html)

However, it’s rather inconvenient for ide users because ideally they don’t want to change anything at gradle config and just hit ‘debug’ button and get the job done. It’s also possible that port 5005 is already occupied at local environment.

I.e. the tooling api should allow to do the following:

  1. Specify that ‘test’ task should be executed at ‘debug’ mode;

  2. Customize the port used for receiving remote debugger connections;

Thanks for the ideas Denis. I’ve exported this to Jira as GRADLE-2797.