Jellytools Test Cases Debugging
Author: Jiri
Skrivanek
Last update: April 7, 2005
This page should help you debug your tests inside the IDE.
Step by step guide
You need two instances of the IDE running at the same time. Actions in
the first
IDE will be marked in
green
color, actions in the second IDE in blue color.
-
start the first IDE which will be used as a
debugger
- open the project with your tests
- optionally open jellytools and jemmy
projects to step into their sources
-
start a second IDE in debugging mode using
the following
command line parameters
netbeans -J-Xdebug
-J-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=8765
- open the project with your tests
-
setup the required libraries to be able to run
your tests internally in the IDE
-
connect from the first IDE to the second
-
from main menu choose: Run -> Attach
Debugger...
-
fill in the Attach dialog
-
Connector: SocketAttach
-
Host: <your_host_name>
-
Port: 8765
-
commit the dialog and wait for the Debugger
Console to open and the message "User program running" to appear in it
-
add breakpoint(s) to the test case source code
-
run the test in the second (debugged) IDE (be
sure
to run it internally)
-
the test should stop at the breakpoint and
you should
be able to normally debug code in the first IDE and see actions in the
second
IDE
If you find a problem, please look at the detailed guide how
to debug NetBeans IDE with the NetBeans debugger.