TestRoots / watchdog

IntelliJ & Eclipse plugin for monitoring how Java applications are developed and tested
http://www.testroots.org
Other
18 stars 10 forks source link

Tracking of other debug events #239

Closed nspruit closed 8 years ago

nspruit commented 8 years ago

This PR adds support for tracking more different types of events that occur while debugging. In particular, the following events are now tracked as well:

  1. The program is suspended due to a breakpoint
  2. The program is suspended by the user (Eclipse only)
  3. A 'Step out' ('Step return' in Eclipse) action is performed by the user
  4. A 'Step into' action is performed by the user
  5. A 'Step over' action is performed by the user
  6. The program is resumed by the user
  7. The user inspects a variable using the 'Inspect' command
  8. The user defines a watch expression
  9. The user evaluates an expression (IntelliJ only)
  10. The user modifies the value of a variable

Before this functionality was implemented, research has been performed to investigate what is and what is not possible using the Eclipse/IntelliJ API. The results of this investigation can be found in the comment here: https://github.com/nspruit/watchdog/issues/3#issuecomment-203817728. This comment also explains why certain events cannot (yet) be tracked.

Tracking event 2. is only possible in Eclipse, as I was not able to find a way to differentiate between 1. and 2. using IntelliJ's API. Therefore, these suspend events are assumed to be caused by breakpoints in IntelliJ.

Tracking event 9. is only possible in IntelliJ, as defining watches and evaluating expressions is done in the same way in Eclipse (using the 'Expressions' view). IntelliJ also has a separate dialog that enables the user to evaluate expressions. The action of opening this dialog is what is tracked for 9.

Inventitech commented 8 years ago

A few comments, but nothing major.

nspruit commented 8 years ago

Thanks! I've proposed fixes for your comments. Hopefully the names are better now