Debugging tests via gradle

From searching online, I’ve found two ways to debug tests via gradle:

  1. Setting the debug property within the test task to true and executing your gradle command without any additional flags
  2. passing the --debug-jvm flag to gradle

In both cases, make sure you create a debug run config (port 5005) and run said config after starting your tests.

Advertisements