Hi,
I tried the example script from 
http://swtbot.org/bugzilla/show_bug.cgi?id=76
http://swtbot.org/bugzilla/show_bug.cgi?id=76  and the tests run correctly,
but when the tested plugin closes I get an exception which I don't know how
to deal with (see attachment, 'jfaceexplorer' is the name of my
plugin-under-test). 
Maybe one of you can give me a hint, if it's a problem with my application,
or the pde tests or even swtbot?
Within eclipse and 'Run-As->SWTBot' the tests run fine...
Thanks,
Stefan

...edit: I don't seem to be able to attach files, so here's the exception:

!ENTRY org.eclipse.ui.workbench 4 0 2008-09-23 16:33:46.139
!MESSAGE jfaceexplorer.View cannot be cast to
org.eclipse.ui.ISelectionListener
!STACK 0
java.lang.ClassCastException: jfaceexplorer.View cannot be cast to
org.eclipse.ui.ISelectionListener
        at jfaceexplorer.View.dispose(View.java:134)
        at
org.eclipse.ui.internal.WorkbenchPartReference.doDisposePart(WorkbenchPartReference.java:730)
        at
org.eclipse.ui.internal.ViewReference.doDisposePart(ViewReference.java:105)
        at
org.eclipse.ui.internal.WorkbenchPartReference.dispose(WorkbenchPartReference.java:681)
        at
org.eclipse.ui.internal.WorkbenchPage.disposePart(WorkbenchPage.java:1682)
        at
org.eclipse.ui.internal.WorkbenchPage.partRemoved(WorkbenchPage.java:1674)
        at org.eclipse.ui.internal.ViewFactory.releaseView(ViewFactory.java:256)
        at org.eclipse.ui.internal.Perspective.dispose(Perspective.java:281)
        at 
org.eclipse.ui.internal.WorkbenchPage.dispose(WorkbenchPage.java:1753)
        at
org.eclipse.ui.internal.WorkbenchWindow.closeAllPages(WorkbenchWindow.java:849)
        at
org.eclipse.ui.internal.WorkbenchWindow.hardClose(WorkbenchWindow.java:1585)
        at
org.eclipse.ui.internal.WorkbenchWindow.busyClose(WorkbenchWindow.java:722)
        at
org.eclipse.ui.internal.WorkbenchWindow.access$0(WorkbenchWindow.java:698)
        at 
org.eclipse.ui.internal.WorkbenchWindow$3.run(WorkbenchWindow.java:814)
        at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
        at 
org.eclipse.ui.internal.WorkbenchWindow.close(WorkbenchWindow.java:812)
        at org.eclipse.jface.window.WindowManager.close(WindowManager.java:109)
        at org.eclipse.ui.internal.Workbench$16.run(Workbench.java:912)
        at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
        at org.eclipse.ui.internal.Workbench.busyClose(Workbench.java:909)
        at org.eclipse.ui.internal.Workbench.access$15(Workbench.java:838)
        at org.eclipse.ui.internal.Workbench$23.run(Workbench.java:1082)
        at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
        at org.eclipse.ui.internal.Workbench.close(Workbench.java:1080)
        at org.eclipse.ui.internal.Workbench.close(Workbench.java:1052)
        at
org.eclipse.ui.internal.testing.WorkbenchTestable$2.run(WorkbenchTestable.java:121)
        at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
        at
org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:133)
        at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3800)
        at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3425)
        at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2382)
        at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2346)
        at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2198)
        at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:493)
        at
org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:288)
        at
org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:488)
        at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
        at jfaceexplorer.Application.start(Application.java:21)
        at 
net.sf.swtbot.eclipse.ui.TestApplication.start(TestApplication.java:45)
        at
org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:193)
        at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
        at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
        at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:382)
        at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:549)
        at org.eclipse.equinox.launcher.Main.basicRun(Main.java:504)
        at org.eclipse.equinox.launcher.Main.run(Main.java:1236)
        at org.eclipse.equinox.launcher.Main.main(Main.java:1212)

-- 
View this message in context: 
http://www.nabble.com/Running-SWTBot-Plugin-Test-from-Ant-tp18342617p19629410.html
Sent from the SWTBot Users List mailing list archive at Nabble.com.


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
SWTBot-users mailing list
SWTBot-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/swtbot-users
http://swtbot.org/ - a functional testing tool for SWT/Eclipse

Reply via email to