How to get terminate/resume button in debug perspective [message #695187] |
Mon, 11 July 2011 04:36  |
Eclipse User |
|
|
|
Hi~
I am trying to use SWTBot to test eclipse debug feature, like set breakpoint, terminate/suspend/resume application, i try to get the terminate button as follow:
bot.toolbarButtonInGroup("terminate","threadGroup").click():
but it failed to find widget "terminte" button, i read eclipse source code, it seems UI is added in a group. I am not sure how to locate this button, anyone has ever encountered this before, thanks~
|
|
|
Re: How to get terminate/resume button in debug perspective [message #695617 is a reply to message #695187] |
Tue, 12 July 2011 03:15  |
Eclipse User |
|
|
|
I found the solution, toolbar buttons like Suspend/Resume/Terminate are sub widgets of debug view, so we need to call toolbar buttons like this way:
SWTBotView view=bot.viewByTitle("Debug");
assertNotNull(view);
view.show();
view.toolbarButton("Suspend").click();
this error happens because i am not familiar with framework of SWTBot and eclipse, hope it can help someone fresh like me~~
|
|
|
Powered by
FUDForum. Page generated in 0.04545 seconds