Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Test and Performance Tools Platform (TPTP) » AGR hangs while playing a recorded simple dialog spawned from ProgressMonitorDia
AGR hangs while playing a recorded simple dialog spawned from ProgressMonitorDia [message #116336] Wed, 24 October 2007 13:30 Go to next message
Susanta Datta is currently offline Susanta Datta
Messages: 1
Registered: July 2009
Junior Member
Hi all, I’ve recoded an AGR test case where a MessageDialog is spawned
from a ProgressMonitorDialog and when the OK button is clicked the
MessageDialog gets closed. Now when I run the AGR test case it opens the
MessageDialog but then hangs. After a while I get a time out error.
Any idea why this is happening?

Here is the XML content
<macro version="1.0">
<shell descriptive="Modeling -
com.ibm.xtools.transform.merge.bvt.agrt..."
id="org.eclipse.ui.internal.WorkbenchWindow" return-code="-1">
<command descriptive="Test sample Action" type="select"
resolverId="org.eclipse.tptp.test.auto.gui.nontrivial" contextId="menus"
widgetId="{{Sample Menu-Test sample Action}}-{{1.0}}"/>
<shell descriptive="Progress Information"
id="org.eclipse.jface.dialogs.ProgressMonitorDialog" return-code="-1">
<shell descriptive="MyTestPlugin Plug-in"
id="org.eclipse.jface.dialogs.MessageDialog" return-code="0">
<command descriptive="OK" type="select"
resolverId="org.eclipse.tptp.test.auto.gui.adaptive" contextId="shell"
widgetId="{{0}}-{{1.0}}"/>
</shell>
</shell>
</shell>
</macro>

Here is the code the invokes the dialog

public void run(IAction action) {
try {
final ProgressMonitorDialog monitorDlg = new
ProgressMonitorDialog(window.getShell());
monitorDlg.run(true, true, new IRunnableWithProgress(){
public void run(IProgressMonitor monitor)throws
InvocationTargetException, InterruptedException {
Display.getDefault().asyncExec(new Runnable(){
public void run() {
MessageDialog.openInformation(
monitorDlg.getShell(),
"MyTestPlugin Plug-in",
"Hello, Eclipse world");
}
});
}
});
} catch (InvocationTargetException e1) {
e1.printStackTrace();
} catch (InterruptedException e1) {
e1.printStackTrace();
}

}


I’m using eclipse 3.3.1 with
org.eclipse.tptp.test.auto.gui_4.3.100.200709211328 plugin.

Thanks in advance for your response!

Susanta
Re: AGR hangs while playing a recorded simple dialog spawned from ProgressMonitorDia [message #117293 is a reply to message #116336] Tue, 06 November 2007 07:47 Go to previous message
Paul Slauenwhite is currently offline Paul Slauenwhite
Messages: 970
Registered: July 2009
Senior Member
Hi Susanta,
I would assume the AGR cannot locate the button on the dialog. For more
information on the solution, see the Widget Resolving Mechanism section in
the AGR documentation:

http://www.eclipse.org/tptp/test/documents/userguides/Intro- Auto-GUI-4-4-0.html#2.4

Also, you may be seeing the symptoms for defect
https://bugs.eclipse.org/bugs/show_bug.cgi?id=167105.

Paul
"Susanta" <susanta_datta@yahoo.com> wrote in message
news:e086447e1c73a54442aeb7960ce3187d$1@www.eclipse.org...
> Hi all, I
Previous Topic:How to find the results(pass/fail) after running test cases
Next Topic:Playback error
Goto Forum:
  


Current Time: Wed Aug 20 14:44:58 EDT 2014

Powered by FUDForum. Page generated in 0.01714 seconds