swtbot-users Mailing List for SWTBot - SWT/Eclipse functional testing (Page 22)
Brought to you by:
kpadegaonkar
You can subscribe to this list here.
| 2008 |
Jan
|
Feb
(14) |
Mar
(6) |
Apr
|
May
(15) |
Jun
(126) |
Jul
(128) |
Aug
(31) |
Sep
(35) |
Oct
(188) |
Nov
(47) |
Dec
(19) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2009 |
Jan
(25) |
Feb
(3) |
Mar
|
Apr
|
May
|
Jun
(2) |
Jul
(2) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
| 2010 |
Jan
(2) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2013 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Hans S. <han...@ya...> - 2008-06-19 07:08:57
|
I have to close the Apache projects. Then the org.rcpmai.test worked. Strange, but that is the solution. I wonder why you are having them in your SVN source tree, because they are already provided by Eclipse as standard plugins. Ketan Padegaonkar <ket...@gm...> wrote: On 18-Jun-08, at 12:53 PM, Hans Schwaebli wrote: > If I close all Eclipse projects except org.rcpmail and > org.rcpmail.test, then the test runs without that error. Same run > configuration in both cases. > > How do you debug SWT Bot and do you know why that error occurs and > how to debug SWT Bot? It's difficult to debug SWTBot because it runs in a non-UI thread and a lot of interesting things happen over a period of time when you switch focus between your application and eclipse. The way I debug SWTBot is to turn on logging. See http://swtbot.svn.sourceforge.net/svnroot/swtbot/trunk/net.sf.swtbot.finder.test/src/log4j.xml If what you want to debug is the launcher, it's next to impossible in eclipse 3.3, this has been fixed in 3.4 https://bugs.eclipse.org/bugs/show_bug.cgi?id=109137 -- Ketan ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ SWTBot-users mailing list SWT...@li... https://lists.sourceforge.net/lists/listinfo/swtbot-users http://swtbot.org/ - a functional testing tool for SWT/Eclipse |
|
From: Ketan P. <ket...@gm...> - 2008-06-18 11:09:19
|
On 18-Jun-08, at 12:53 PM, Hans Schwaebli wrote: > If I close all Eclipse projects except org.rcpmail and > org.rcpmail.test, then the test runs without that error. Same run > configuration in both cases. > > How do you debug SWT Bot and do you know why that error occurs and > how to debug SWT Bot? It's difficult to debug SWTBot because it runs in a non-UI thread and a lot of interesting things happen over a period of time when you switch focus between your application and eclipse. The way I debug SWTBot is to turn on logging. See http://swtbot.svn.sourceforge.net/svnroot/swtbot/trunk/net.sf.swtbot.finder.test/src/log4j.xml If what you want to debug is the launcher, it's next to impossible in eclipse 3.3, this has been fixed in 3.4 https://bugs.eclipse.org/bugs/show_bug.cgi?id=109137 -- Ketan |
|
From: paulo c. <pjc...@gm...> - 2008-06-18 11:03:34
|
Dear Guillaume, It is now working. here's what I've done: I had added the jars as plugin dependencies already. I just did a double check to see if they were ok. Then I went to the run config dialog to the plugins tab and I switched to 'plugins selected below' and then I clicked 'validate plugins' and unchecked those who were causing trouble. (So, I guess the prob had something to do with my eclipse instalation.) thanks a lot, p. On Wed, Jun 18, 2008 at 11:28 AM, Guillaume Bourel <gb...@ag...> wrote: > Hi Paulo, > rcpmail is a RCP application so jars should be added as plugins > dependencies. > If they already are, did you check they are really loaded in the run > configuration dialog (plugins tab => add required plugins) > > paulo carreira a écrit : >> Hi. >> >> I checked out both org.rcpmail and org.rcpmail.example had them >> both compiling. >> >> When I launch org.rcpmail.MyFirstTest, I always get a >> java.lang.NoClassDefFoundError: >> org/apache/commons/collections/map/MultiValueMap. >> >> I'm using commons-collections-3.2.1.jar and >> commons-logging-1.1.1.jar. And I have tried to add them to classpath >> in every way I could think of. Any hints? the trace follows below: >> >> junit.framework.AssertionFailedError: Exception in constructor: >> testThisPasses (java.lang.NoClassDefFoundError: >> org/apache/commons/collections/map/MultiValueMap >> at net.sf.swtbot.resolvers.Resolver.<init>(Resolver.java:36) >> at net.sf.swtbot.resolvers.Resolvable.<init>(Resolvable.java:35) >> at net.sf.swtbot.resolvers.DefaultChildrenResolver.<init>(DefaultChildrenResolver.java:28) >> at net.sf.swtbot.finder.ControlFinder.<init>(ControlFinder.java:75) >> at net.sf.swtbot.SWTBot.<init>(SWTBot.java:86) >> at net.sf.swtbot.SWTBotTestCase.<init>(SWTBotTestCase.java:37) >> at net.sf.swtbot.eclipse.finder.SWTBotTestCase.<init>(SWTBotTestCase.java:23) >> at org.rcpmail.MyFirstTest.<init>(MyFirstTest.java:7) >> at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) >> at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) >> at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) >> at java.lang.reflect.Constructor.newInstance(Constructor.java:513) >> at junit.framework.TestSuite.createTest(TestSuite.java:54) >> at junit.framework.TestSuite.addTestMethod(TestSuite.java:280) >> at junit.framework.TestSuite.<init>(TestSuite.java:140) >> at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestLoader.getTest(JUnit3TestLoader.java:102) >> at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestLoader.loadTests(JUnit3TestLoader.java:59) >> at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:445) >> at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673) >> at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386) >> at org.eclipse.pde.internal.junit.runtime.RemotePluginTestRunner.main(RemotePluginTestRunner.java:58) >> at net.sf.swtbot.eclipse.ui.TestApplication.runTests(TestApplication.java:112) >> at org.eclipse.ui.internal.testing.WorkbenchTestable$1.run(WorkbenchTestable.java:68) >> at java.lang.Thread.run(Thread.java:619) >> ) >> at junit.framework.Assert.fail(Assert.java:47) >> at junit.framework.TestSuite$1.runTest(TestSuite.java:90) >> at junit.framework.TestCase.runBare(TestCase.java:130) >> at junit.framework.TestResult$1.protect(TestResult.java:106) >> at junit.framework.TestResult.runProtected(TestResult.java:124) >> at junit.framework.TestResult.run(TestResult.java:109) >> at junit.framework.TestCase.run(TestCase.java:120) >> at junit.framework.TestSuite.runTest(TestSuite.java:230) >> at junit.framework.TestSuite.run(TestSuite.java:225) >> at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130) >> at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) >> at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460) >> at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673) >> at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386) >> at org.eclipse.pde.internal.junit.runtime.RemotePluginTestRunner.main(RemotePluginTestRunner.java:58) >> at net.sf.swtbot.eclipse.ui.TestApplication.runTests(TestApplication.java:112) >> at org.eclipse.ui.internal.testing.WorkbenchTestable$1.run(WorkbenchTestable.java:68) >> at java.lang.Thread.run(Thread.java:619) >> > > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > _______________________________________________ > SWTBot-users mailing list > SWT...@li... > https://lists.sourceforge.net/lists/listinfo/swtbot-users > http://swtbot.org/ - a functional testing tool for SWT/Eclipse > > -- paulo. Paulo Carreira http://carreira.planetaclix.pt |
|
From: Ketan P. <ket...@gm...> - 2008-06-18 11:00:39
|
On 18-Jun-08, at 4:15 PM, Guillaume Bourel wrote: > but menu.menu(String) use the MenuFinder.findMenus which isn't > returning menu items if they are not enabled. That's the intended behavior to speed up things, by not searching inside things that are not enabled, this is a problem in some cases. You can override this by setting: Finder#setShouldFindInvisibleControls(). There's a finder in SWTBot See SWTBotView#findWidget(IWorkbenchPartReference view, Finder finder) for usage. There's no easy hook to inject a finder into an instance of SWTBotWidget. Do file a patch if you can think of something that's quick. -- Ketan |
|
From: Ketan P. <ket...@gm...> - 2008-06-18 10:47:25
|
Can you try this, and see what happens ? 1. Download and install eclipse-SDK-3.3, this is also known as the classic version 2. Download and install swtbot from the update site http://swtbot.sourceforge.net/artifacts/1.1.0/update-site/ 3. Download the rcp examples from http://swtbot.svn.sourceforge.net/svnroot/swtbot/trunk/examples/rcp 4. Open the class org.rcpmail.AllTests 5. Right click on AllTests, click "Run As>Open Run Dialog" 6. Create a new under "SWTBot Tests" 7. Set the test runner to JUnit3 8. Switch to the Main tab 9. Select "Run As Product" "org.rcpmail.product" 10. Click run I've typed these steps in the same order that I performed them, and should work for you. -- Ketan On 18-Jun-08, at 3:37 PM, paulo carreira wrote: > Hi. > > I checked out both org.rcpmail and org.rcpmail.example had them > both compiling. > > When I launch org.rcpmail.MyFirstTest, I always get a > java.lang.NoClassDefFoundError: > org/apache/commons/collections/map/MultiValueMap. > > I'm using commons-collections-3.2.1.jar and > commons-logging-1.1.1.jar. And I have tried to add them to classpath > in every way I could think of. Any hints? the trace follows below: > > junit.framework.AssertionFailedError: Exception in constructor: > testThisPasses (java.lang.NoClassDefFoundError: > org/apache/commons/collections/map/MultiValueMap > at net.sf.swtbot.resolvers.Resolver.<init>(Resolver.java:36) > at net.sf.swtbot.resolvers.Resolvable.<init>(Resolvable.java:35) > at > net > .sf > .swtbot > .resolvers > .DefaultChildrenResolver.<init>(DefaultChildrenResolver.java:28) > at net.sf.swtbot.finder.ControlFinder.<init>(ControlFinder.java:75) > at net.sf.swtbot.SWTBot.<init>(SWTBot.java:86) > at net.sf.swtbot.SWTBotTestCase.<init>(SWTBotTestCase.java:37) > at > net > .sf.swtbot.eclipse.finder.SWTBotTestCase.<init>(SWTBotTestCase.java: > 23) > at org.rcpmail.MyFirstTest.<init>(MyFirstTest.java:7) > at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native > Method) > at > sun > .reflect > .NativeConstructorAccessorImpl > .newInstance(NativeConstructorAccessorImpl.java:39) > at > sun > .reflect > .DelegatingConstructorAccessorImpl > .newInstance(DelegatingConstructorAccessorImpl.java:27) > at java.lang.reflect.Constructor.newInstance(Constructor.java:513) > at junit.framework.TestSuite.createTest(TestSuite.java:54) > at junit.framework.TestSuite.addTestMethod(TestSuite.java:280) > at junit.framework.TestSuite.<init>(TestSuite.java:140) > at > org > .eclipse > .jdt > .internal > .junit.runner.junit3.JUnit3TestLoader.getTest(JUnit3TestLoader.java: > 102) > at > org > .eclipse > .jdt > .internal > .junit > .runner.junit3.JUnit3TestLoader.loadTests(JUnit3TestLoader.java:59) > at > org > .eclipse > .jdt > .internal > .junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:445) > at > org > .eclipse > .jdt > .internal > .junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673) > at > org > .eclipse > .jdt > .internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386) > at > org > .eclipse > .pde > .internal > .junit > .runtime.RemotePluginTestRunner.main(RemotePluginTestRunner.java:58) > at > net > .sf.swtbot.eclipse.ui.TestApplication.runTests(TestApplication.java: > 112) > at org.eclipse.ui.internal.testing.WorkbenchTestable > $1.run(WorkbenchTestable.java:68) > at java.lang.Thread.run(Thread.java:619) > ) > at junit.framework.Assert.fail(Assert.java:47) > at junit.framework.TestSuite$1.runTest(TestSuite.java:90) > at junit.framework.TestCase.runBare(TestCase.java:130) > at junit.framework.TestResult$1.protect(TestResult.java:106) > at junit.framework.TestResult.runProtected(TestResult.java:124) > at junit.framework.TestResult.run(TestResult.java:109) > at junit.framework.TestCase.run(TestCase.java:120) > at junit.framework.TestSuite.runTest(TestSuite.java:230) > at junit.framework.TestSuite.run(TestSuite.java:225) > at > org > .eclipse > .jdt > .internal > .junit > .runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130) > at > org > .eclipse > .jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) > at > org > .eclipse > .jdt > .internal > .junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460) > at > org > .eclipse > .jdt > .internal > .junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673) > at > org > .eclipse > .jdt > .internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386) > at > org > .eclipse > .pde > .internal > .junit > .runtime.RemotePluginTestRunner.main(RemotePluginTestRunner.java:58) > at > net > .sf.swtbot.eclipse.ui.TestApplication.runTests(TestApplication.java: > 112) > at org.eclipse.ui.internal.testing.WorkbenchTestable > $1.run(WorkbenchTestable.java:68) > at java.lang.Thread.run(Thread.java:619) > -- > paulo. > > Paulo Carreira > http://carreira.planetaclix.pt > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > _______________________________________________ > SWTBot-users mailing list > SWT...@li... > https://lists.sourceforge.net/lists/listinfo/swtbot-users > http://swtbot.org/ - a functional testing tool for SWT/Eclipse > Cheers, Ketan Padegaonkar, I blog... therefore I am... http://ketan.padegaonkar.name http://swtbot.org/ - a functional testing tool for SWT/Eclipse |
|
From: Guillaume B. <gb...@ag...> - 2008-06-18 10:47:02
|
Hey,
I tried to check if sub-menus are enabled or not by doing this :
SWTBotMenu menu = ps.contextMenu("My menu with sub-menus");
menu.click();
SWTBotMenu submenu = menu.menu("First sub-menu");
asserTrue(subMenu.isEnabled())
but menu.menu(String) use the MenuFinder.findMenus which isn't returning
menu items if they are not enabled.
How should I check if the sub-menus are enable or not ?
Cheers,
Guillaume.
|
|
From: Guillaume B. <gb...@ag...> - 2008-06-18 10:38:32
|
Hey Hans, all errors such as " "*application" could not be found in the registry " are RCP exceptions. If you take a look at Eclipse RCP plugins definition (without SWTBot) you may understand them better. (btw I checked out the 1.1 sources too and got no error when I start org.rcpmail.test ) Cheers, Guillaume Hans Schwaebli a écrit : > I want to debug SWT Bot itself. > > I installed the 1.1 version plugins of SWT Bot and checked out the 1.1 > sources. When I then start the org.rcpmail.test I get an error: > > RuntimeException: Application > "net.sf.swtbot.eclipse.ui.swtbottestapplication" could not be found in > the registry. The applications available are: > net.sf.swtbot.eclipse.headless.coretestapplication, > net.sf.swtbot.eclipse.headless.swtbottestapplication, > org.eclipse.ant.core.antRunner, org.eclipse.equinox.app.error, > org.eclipse.jdt.apt.core.aptBuild, > org.eclipse.jdt.core.JavaCodeFormatter, org.eclipse.pde.build.Build, > org.eclipse.pde.junit.runtime.uitestapplication, > org.eclipse.pde.junit.runtime.legacytestapplication, > org.eclipse.pde.junit.runtime.coretestapplication, > org.eclipse.ui.ide.workbench, > org.eclipse.update.core.standaloneUpdate, > org.eclipse.update.core.siteOptimizer, org.rcpmail.application. > at > org.eclipse.equinox.internal.app.EclipseAppContainer.startDefaultApp(EclipseAppContainer.java:242) > > If I close all Eclipse projects except org.rcpmail and > org.rcpmail.test, then the test runs without that error. Same run > configuration in both cases. > > How do you debug SWT Bot and do you know why that error occurs and how > to debug SWT Bot? > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > ------------------------------------------------------------------------ > > _______________________________________________ > SWTBot-users mailing list > SWT...@li... > https://lists.sourceforge.net/lists/listinfo/swtbot-users > http://swtbot.org/ - a functional testing tool for SWT/Eclipse > > |
|
From: Guillaume B. <gb...@ag...> - 2008-06-18 10:30:58
|
Hi Paulo, rcpmail is a RCP application so jars should be added as plugins dependencies. If they already are, did you check they are really loaded in the run configuration dialog (plugins tab => add required plugins) paulo carreira a écrit : > Hi. > > I checked out both org.rcpmail and org.rcpmail.example had them > both compiling. > > When I launch org.rcpmail.MyFirstTest, I always get a > java.lang.NoClassDefFoundError: > org/apache/commons/collections/map/MultiValueMap. > > I'm using commons-collections-3.2.1.jar and > commons-logging-1.1.1.jar. And I have tried to add them to classpath > in every way I could think of. Any hints? the trace follows below: > > junit.framework.AssertionFailedError: Exception in constructor: > testThisPasses (java.lang.NoClassDefFoundError: > org/apache/commons/collections/map/MultiValueMap > at net.sf.swtbot.resolvers.Resolver.<init>(Resolver.java:36) > at net.sf.swtbot.resolvers.Resolvable.<init>(Resolvable.java:35) > at net.sf.swtbot.resolvers.DefaultChildrenResolver.<init>(DefaultChildrenResolver.java:28) > at net.sf.swtbot.finder.ControlFinder.<init>(ControlFinder.java:75) > at net.sf.swtbot.SWTBot.<init>(SWTBot.java:86) > at net.sf.swtbot.SWTBotTestCase.<init>(SWTBotTestCase.java:37) > at net.sf.swtbot.eclipse.finder.SWTBotTestCase.<init>(SWTBotTestCase.java:23) > at org.rcpmail.MyFirstTest.<init>(MyFirstTest.java:7) > at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) > at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) > at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) > at java.lang.reflect.Constructor.newInstance(Constructor.java:513) > at junit.framework.TestSuite.createTest(TestSuite.java:54) > at junit.framework.TestSuite.addTestMethod(TestSuite.java:280) > at junit.framework.TestSuite.<init>(TestSuite.java:140) > at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestLoader.getTest(JUnit3TestLoader.java:102) > at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestLoader.loadTests(JUnit3TestLoader.java:59) > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:445) > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673) > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386) > at org.eclipse.pde.internal.junit.runtime.RemotePluginTestRunner.main(RemotePluginTestRunner.java:58) > at net.sf.swtbot.eclipse.ui.TestApplication.runTests(TestApplication.java:112) > at org.eclipse.ui.internal.testing.WorkbenchTestable$1.run(WorkbenchTestable.java:68) > at java.lang.Thread.run(Thread.java:619) > ) > at junit.framework.Assert.fail(Assert.java:47) > at junit.framework.TestSuite$1.runTest(TestSuite.java:90) > at junit.framework.TestCase.runBare(TestCase.java:130) > at junit.framework.TestResult$1.protect(TestResult.java:106) > at junit.framework.TestResult.runProtected(TestResult.java:124) > at junit.framework.TestResult.run(TestResult.java:109) > at junit.framework.TestCase.run(TestCase.java:120) > at junit.framework.TestSuite.runTest(TestSuite.java:230) > at junit.framework.TestSuite.run(TestSuite.java:225) > at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130) > at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460) > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673) > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386) > at org.eclipse.pde.internal.junit.runtime.RemotePluginTestRunner.main(RemotePluginTestRunner.java:58) > at net.sf.swtbot.eclipse.ui.TestApplication.runTests(TestApplication.java:112) > at org.eclipse.ui.internal.testing.WorkbenchTestable$1.run(WorkbenchTestable.java:68) > at java.lang.Thread.run(Thread.java:619) > |
|
From: paulo c. <pjc...@gm...> - 2008-06-18 10:07:17
|
Hi.
I checked out both org.rcpmail and org.rcpmail.example had them
both compiling.
When I launch org.rcpmail.MyFirstTest, I always get a
java.lang.NoClassDefFoundError:
org/apache/commons/collections/map/MultiValueMap.
I'm using commons-collections-3.2.1.jar and
commons-logging-1.1.1.jar. And I have tried to add them to classpath
in every way I could think of. Any hints? the trace follows below:
junit.framework.AssertionFailedError: Exception in constructor:
testThisPasses (java.lang.NoClassDefFoundError:
org/apache/commons/collections/map/MultiValueMap
at net.sf.swtbot.resolvers.Resolver.<init>(Resolver.java:36)
at net.sf.swtbot.resolvers.Resolvable.<init>(Resolvable.java:35)
at net.sf.swtbot.resolvers.DefaultChildrenResolver.<init>(DefaultChildrenResolver.java:28)
at net.sf.swtbot.finder.ControlFinder.<init>(ControlFinder.java:75)
at net.sf.swtbot.SWTBot.<init>(SWTBot.java:86)
at net.sf.swtbot.SWTBotTestCase.<init>(SWTBotTestCase.java:37)
at net.sf.swtbot.eclipse.finder.SWTBotTestCase.<init>(SWTBotTestCase.java:23)
at org.rcpmail.MyFirstTest.<init>(MyFirstTest.java:7)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at junit.framework.TestSuite.createTest(TestSuite.java:54)
at junit.framework.TestSuite.addTestMethod(TestSuite.java:280)
at junit.framework.TestSuite.<init>(TestSuite.java:140)
at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestLoader.getTest(JUnit3TestLoader.java:102)
at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestLoader.loadTests(JUnit3TestLoader.java:59)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:445)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
at org.eclipse.pde.internal.junit.runtime.RemotePluginTestRunner.main(RemotePluginTestRunner.java:58)
at net.sf.swtbot.eclipse.ui.TestApplication.runTests(TestApplication.java:112)
at org.eclipse.ui.internal.testing.WorkbenchTestable$1.run(WorkbenchTestable.java:68)
at java.lang.Thread.run(Thread.java:619)
)
at junit.framework.Assert.fail(Assert.java:47)
at junit.framework.TestSuite$1.runTest(TestSuite.java:90)
at junit.framework.TestCase.runBare(TestCase.java:130)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:120)
at junit.framework.TestSuite.runTest(TestSuite.java:230)
at junit.framework.TestSuite.run(TestSuite.java:225)
at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
at org.eclipse.pde.internal.junit.runtime.RemotePluginTestRunner.main(RemotePluginTestRunner.java:58)
at net.sf.swtbot.eclipse.ui.TestApplication.runTests(TestApplication.java:112)
at org.eclipse.ui.internal.testing.WorkbenchTestable$1.run(WorkbenchTestable.java:68)
at java.lang.Thread.run(Thread.java:619)
--
paulo.
Paulo Carreira
http://carreira.planetaclix.pt
|
|
From: Hans S. <han...@ya...> - 2008-06-18 07:23:30
|
I want to debug SWT Bot itself.
I installed the 1.1 version plugins of SWT Bot and checked out the 1.1 sources. When I then start the org.rcpmail.test I get an error:
RuntimeException: Application "net.sf.swtbot.eclipse.ui.swtbottestapplication" could not be found in the registry. The applications available are: net.sf.swtbot.eclipse.headless.coretestapplication, net.sf.swtbot.eclipse.headless.swtbottestapplication, org.eclipse.ant.core.antRunner, org.eclipse.equinox.app.error, org.eclipse.jdt.apt.core.aptBuild, org.eclipse.jdt.core.JavaCodeFormatter, org.eclipse.pde.build.Build, org.eclipse.pde.junit.runtime.uitestapplication, org.eclipse.pde.junit.runtime.legacytestapplication, org.eclipse.pde.junit.runtime.coretestapplication, org.eclipse.ui.ide.workbench, org.eclipse.update.core.standaloneUpdate, org.eclipse.update.core.siteOptimizer, org.rcpmail.application.
at org.eclipse.equinox.internal.app.EclipseAppContainer.startDefaultApp(EclipseAppContainer.java:242)
If I close all Eclipse projects except org.rcpmail and org.rcpmail.test, then the test runs without that error. Same run configuration in both cases.
How do you debug SWT Bot and do you know why that error occurs and how to debug SWT Bot?
|
|
From: Ketan P. <ket...@gm...> - 2008-06-18 04:30:49
|
What Somesh has mentioned is useful for finding controls 'inside' the composite. See the mailBox() at http://swtbot.svn.sourceforge.net/svnroot/swtbot/trunk/examples/rcp/org.rcpmail.test/src/org/rcpmail/MessageCreateTest.java . It essentially finds a tree inside the "Mailboxes" view. To answer the rest of your question, if it's possible to get to the toolbar and menubars of a view. This is not provided yet, and I've seen that you've filed bugs for that, thanks! I think that should be possible, if I can programatically get a handle to these widgets. Cheers, Ketan Padegaonkar, I blog... therefore I am... http://ketan.padegaonkar.name http://swtbot.org/ - a functional testing tool for SWT/Eclipse On 18-Jun-08, at 9:40 AM, Somesh Sasalatti wrote: > Hi Steve, > if you can't use the bot directly to find a widget, you can use the > ControlFinder or the ChildControlFinder, set a breakpoint, debug and > look for anything unique that you can use to identify it. You can > then get that widget, cast it if need be and use it. Sometimes this > needs to be done in the UI thread so you can use the UIThreadRunnable > > Take a look at the rcp test code. it show you how to use the control > finder. > UIThreadRunnable is pretty straight forward too. it's just a wrapper > for running anything in the display and provides some utility > runnables. > > hope this helps > Somesh > > > On Tue, Jun 17, 2008 at 6:34 PM, Paulin <pa...@sp...> wrote: > Hello, > > I'm trying to figure out how to access the menu within a view. > > I have the view but the menu (which doesn't have a name just the > little down arrow) doesn't seem to have a way to be access through > the SWTBot. However on the site it says acess to the controls of > the View is provided so I'm thinking I'm missing something. > > Any help would be appreciated. > > Thanks > steve |
|
From: Somesh S. <som...@gm...> - 2008-06-18 04:10:19
|
Hi Steve, if you can't use the bot directly to find a widget, you can use the ControlFinder or the ChildControlFinder, set a breakpoint, debug and look for anything unique that you can use to identify it. You can then get that widget, cast it if need be and use it. Sometimes this needs to be done in the UI thread so you can use the UIThreadRunnable Take a look at the rcp test code. it show you how to use the control finder. UIThreadRunnable is pretty straight forward too. it's just a wrapper for running anything in the display and provides some utility runnables. hope this helps Somesh On Tue, Jun 17, 2008 at 6:34 PM, Paulin <pa...@sp...> wrote: > Hello, > > I'm trying to figure out how to access the menu within a view. > > I have the view but the menu (which doesn't have a name just the little > down arrow) doesn't seem to have a way to be access through the SWTBot. > However on the site it says acess to the controls of the View is provided so > I'm thinking I'm missing something. > > Any help would be appreciated. > > Thanks > steve > > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > _______________________________________________ > SWTBot-users mailing list > SWT...@li... > https://lists.sourceforge.net/lists/listinfo/swtbot-users > http://swtbot.org/ - a functional testing tool for SWT/Eclipse > > > |
|
From: Paulin <pa...@sp...> - 2008-06-18 01:34:45
|
Hello, I'm trying to figure out how to access the menu within a view. I have the view but the menu (which doesn't have a name just the little down arrow) doesn't seem to have a way to be access through the SWTBot. However on the site it says acess to the controls of the View is provided so I'm thinking I'm missing something. Any help would be appreciated. Thanks steve |
|
From: Ketan P. <ket...@gm...> - 2008-06-16 17:49:02
|
There's nothing that can be done about this. Executing a plugin test needs that you have (part of) pde installed in the rcp application. The way I've solved it is to have a PDE build in place that builds against one target platform and tests against another. The developers on the team all use the classic eclipse 3.3. CruiseControl uses the standard 'eclipse for java developers' Cheers, Ketan Padegaonkar, I blog... therefore I am... http://ketan.padegaonkar.name http://swtbot.org/ - a functional testing tool for SWT/Eclipse On 16-Jun-08, at 10:39 PM, Hans Schwaebli wrote: > I just want to assure you that when this works for us testing our > RCP application, I will contribute in support. Would be a great > thing to use it because I am very lucky to avoid heavy weight > solutions like Squish or QF Test. > > But here is now my new question. I got farther, but new problems > arose. > > For our RCP application I have to configure in Eclipse > "Windows>Preferences->Plug-in-Development>Target Platform>Target > Platform>Plug-ins". There I point to another folder, not the > standard Eclipse plugins folder. It is because our RCP application > doesn't need all the plugins of Eclipse. > > When I add the RCPMail example to my Eclipse, I get compile errors > because of that. For example all the SWT Bot plugins are not known > because of the above setting. So I copy the SWT Plugins and some > other plugins needed for SWT Bot to the RCP application plugins > folder and refresh Eclipse preferences. > > But I still get compile errors and cannot start the RCPMail example > and after adding the additional plugins cannot start our RCP > aplication anymore. So it seems that it doesn't fit together right > now. > > I will fight my way through to get it working. Because of the time > zone I write you this now. Maybe you have an idea or a link to a How- > to or so. Otherwise I try and would write you again on this if I > don't succeed. > > I hope I could describe my problem. It is a little bit hard to > explain. |
|
From: Hans S. <han...@ya...> - 2008-06-16 17:38:24
|
I just want to assure you that when this works for us testing our RCP application, I will contribute in support. Would be a great thing to use it because I am very lucky to avoid heavy weight solutions like Squish or QF Test.
But here is now my new question. I got farther, but new problems arose.
For our RCP application I have to configure in Eclipse "Windows>Preferences->Plug-in-Development>Target Platform>Target Platform>Plug-ins". There I point to another folder, not the standard Eclipse plugins folder. It is because our RCP application doesn't need all the plugins of Eclipse.
When I add the RCPMail example to my Eclipse, I get compile errors because of that. For example all the SWT Bot plugins are not known because of the above setting. So I copy the SWT Plugins and some other plugins needed for SWT Bot to the RCP application plugins folder and refresh Eclipse preferences.
But I still get compile errors and cannot start the RCPMail example and after adding the additional plugins cannot start our RCP aplication anymore. So it seems that it doesn't fit together right now.
I will fight my way through to get it working. Because of the time zone I write you this now. Maybe you have an idea or a link to a How-to or so. Otherwise I try and would write you again on this if I don't succeed.
I hope I could describe my problem. It is a little bit hard to explain.
|
|
From: Hans S. <han...@ya...> - 2008-06-16 09:48:18
|
Please don't forget about the posting below. I just want to add this information for finding the reason why that error occurs: If I run the Eclpse project net.sf.swtbot.eclipse.ui as an Eclipse application, I get the same error: "Application "net.sf.swtbot.eclipse.ui.swtbottestapplication" could not be found in the registry." I think it has nothing to do with the lauch configuration. I simply start it the normal way, like I start org.rcpmail. But the latter works (starts), the former produces an error. So there might be something misconfigured in the plugin "net.sf.swtbot.eclipse.ui" itself I assume. Maybe that information helps you to find an solution. Hans Schwaebli <han...@ya...> wrote: I am not sure if I understand you completely. As I wrote previously, I followed your instructions on http://swtbot.sourceforge.net/site/users-guide.html exactly. When I run the test, the error which I mentioned occured. I did it exactly as it is written on that page, which the same configurations. And I even tried different configurations. Same error all the time. Of course I experimented with the start configuration for the rcpmail tests, and got always the same error, which I mentioned. For example I run the test as a product "org.rcpmail.product" or run as application "org.rcpmail.application". You didn't answer yet a minor question of me, what Eclipse version SWT Bot 1.1 requires. Can you please tell me? But the most important thing to me is to get rid of that error, to find its cause. What is wrong? Did you mean, that the RCP example tests only run when started from Ant? If yes (which I would find strange), can you provide me the Ant statement to start them? Please. Ketan Padegaonkar <ket...@gm...> wrote: On 16-Jun-08, at 1:33 PM, Hans Schwaebli wrote: > I don't understand what you want to tell me by that. > > I am willing to provide support for SWT Bot once I understood to use > it. I am no information leecher. My apologies if I sounded offensive there. > This was an extra information to you. The point is that when I start > the rcpmail test, the mentioned error occurs. I compared the run > configuration with the link you mentioned and see no differences. > > What is wrong? I simply want to start the test org.rcpmail.test > > As I wrote before, I start it as a SWTBot Test, as it should be. But > the error occurs (see stack trace which I posted in this thread). In the case of the RCP mail example you'll need to run the test as a product "org.rcpmail.product" or run as application "org.rcpmail.application". The swtbot applications that you see running are to run SWTBot tests from within ant and are *not* to be intended to be used from within eclipse. -- Ketan ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ SWTBot-users mailing list SWT...@li... https://lists.sourceforge.net/lists/listinfo/swtbot-users http://swtbot.org/ - a functional testing tool for SWT/Eclipse ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php_______________________________________________ SWTBot-users mailing list SWT...@li... https://lists.sourceforge.net/lists/listinfo/swtbot-users http://swtbot.org/ - a functional testing tool for SWT/Eclipse |
|
From: Hans S. <han...@ya...> - 2008-06-16 09:14:30
|
I am not sure if I understand you completely. As I wrote previously, I followed your instructions on http://swtbot.sourceforge.net/site/users-guide.html exactly. When I run the test, the error which I mentioned occured. I did it exactly as it is written on that page, which the same configurations. And I even tried different configurations. Same error all the time. Of course I experimented with the start configuration for the rcpmail tests, and got always the same error, which I mentioned. For example I run the test as a product "org.rcpmail.product" or run as application "org.rcpmail.application". You didn't answer yet a minor question of me, what Eclipse version SWT Bot 1.1 requires. Can you please tell me? But the most important thing to me is to get rid of that error, to find its cause. What is wrong? Did you mean, that the RCP example tests only run when started from Ant? If yes (which I would find strange), can you provide me the Ant statement to start them? Please. Ketan Padegaonkar <ket...@gm...> wrote: On 16-Jun-08, at 1:33 PM, Hans Schwaebli wrote: > I don't understand what you want to tell me by that. > > I am willing to provide support for SWT Bot once I understood to use > it. I am no information leecher. My apologies if I sounded offensive there. > This was an extra information to you. The point is that when I start > the rcpmail test, the mentioned error occurs. I compared the run > configuration with the link you mentioned and see no differences. > > What is wrong? I simply want to start the test org.rcpmail.test > > As I wrote before, I start it as a SWTBot Test, as it should be. But > the error occurs (see stack trace which I posted in this thread). In the case of the RCP mail example you'll need to run the test as a product "org.rcpmail.product" or run as application "org.rcpmail.application". The swtbot applications that you see running are to run SWTBot tests from within ant and are *not* to be intended to be used from within eclipse. -- Ketan ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ SWTBot-users mailing list SWT...@li... https://lists.sourceforge.net/lists/listinfo/swtbot-users http://swtbot.org/ - a functional testing tool for SWT/Eclipse |
|
From: Ketan P. <ket...@gm...> - 2008-06-16 08:56:03
|
On 16-Jun-08, at 1:33 PM, Hans Schwaebli wrote: > I don't understand what you want to tell me by that. > > I am willing to provide support for SWT Bot once I understood to use > it. I am no information leecher. My apologies if I sounded offensive there. > This was an extra information to you. The point is that when I start > the rcpmail test, the mentioned error occurs. I compared the run > configuration with the link you mentioned and see no differences. > > What is wrong? I simply want to start the test org.rcpmail.test > > As I wrote before, I start it as a SWTBot Test, as it should be. But > the error occurs (see stack trace which I posted in this thread). In the case of the RCP mail example you'll need to run the test as a product "org.rcpmail.product" or run as application "org.rcpmail.application". The swtbot applications that you see running are to run SWTBot tests from within ant and are *not* to be intended to be used from within eclipse. -- Ketan |
|
From: Hans S. <han...@ya...> - 2008-06-16 08:25:37
|
I tried that example now on http://swtbot.sourceforge.net/site/users-guide.html I get the same error like with the rcpmai test. I am using Eclipse Classic 3.3.2 by the way. I hope this is okay, because I don't know what version is actually required. I am quite sure its a little thing which is wrong, but I can't figure it out. Can you please tell me? java.lang.RuntimeException: Application "net.sf.swtbot.eclipse.ui.swtbottestapplication" could not be found in the registry. The applications available are: net.sf.swtbot.eclipse.headless.coretestapplication, net.sf.swtbot.eclipse.headless.swtbottestapplication, org.eclipse.ant.core.antRunner, org.eclipse.equinox.app.error, org.eclipse.jdt.apt.core.aptBuild, org.eclipse.jdt.core.JavaCodeFormatter, org.eclipse.pde.build.Build, org.eclipse.pde.junit.runtime.uitestapplication, org.eclipse.pde.junit.runtime.legacytestapplication, org.eclipse.pde.junit.runtime.coretestapplication, org.eclipse.ui.ide.workbench, org.eclipse.update.core.standaloneUpdate, org.eclipse.update.core.siteOptimizer, org.rcpmail.application. at org.eclipse.equinox.internal.app.EclipseAppContainer.startDefaultApp(EclipseAppContainer.java:242) at org.eclipse.equinox.internal.app.EclipseAppContainer.start(EclipseAppContainer.java:98) at org.eclipse.equinox.internal.app.Activator.addingService(Activator.java:112) at org.osgi.util.tracker.ServiceTracker$Tracked.trackAdding(ServiceTracker.java:1064) at org.osgi.util.tracker.ServiceTracker$Tracked.trackInitialServices(ServiceTracker.java:926) at org.osgi.util.tracker.ServiceTracker.open(ServiceTracker.java:330) at org.osgi.util.tracker.ServiceTracker.open(ServiceTracker.java:274) at org.eclipse.equinox.internal.app.Activator.start(Activator.java:54) at org.eclipse.osgi.framework.internal.core.BundleContextImpl$2.run(BundleContextImpl.java:999) at java.security.AccessController.doPrivileged(Native Method) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:993) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:974) at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:346) at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:260) at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:400) at org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:111) at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClass(ClasspathManager.java:417) at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.findLocalClass(DefaultClassLoader.java:189) at org.eclipse.osgi.framework.internal.core.BundleLoader.findLocalClass(BundleLoader.java:340) at org.eclipse.osgi.framework.internal.core.SingleSourcePackage.loadClass(SingleSourcePackage.java:37) at org.eclipse.osgi.framework.internal.core.BundleLoader.findClassInternal(BundleLoader.java:405) at org.eclipse.osgi.framework.internal.core.BundleLoader.findClass(BundleLoader.java:369) at org.eclipse.osgi.framework.internal.core.BundleLoader.findClass(BundleLoader.java:357) at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:83) at java.lang.ClassLoader.loadClass(ClassLoader.java:251) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319) at org.eclipse.core.internal.runtime.PlatformActivator.startAppContainer(PlatformActivator.java:47) at org.eclipse.core.internal.runtime.PlatformActivator.start(PlatformActivator.java:32) at org.eclipse.osgi.framework.internal.core.BundleContextImpl$2.run(BundleContextImpl.java:999) at java.security.AccessController.doPrivileged(Native Method) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:993) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:974) at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:346) at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:350) at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1118) at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:634) at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:508) at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:282) at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:468) at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:195) at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:297) Ketan Padegaonkar <ket...@gm...> wrote: http://swtbot.sourceforge.net/site/users-guide.html On 13-Jun-08, at 8:50 PM, Hans Schwaebli wrote: > When I start the Eclipse project "net.sf.swtbot.eclipse.ui" with > "Run as Eclipse Application" I get the same error message. There > seems to be something wrong. I compared that project (version 1.1) > against the head, but there are no changes. Is it a bug? > > On the page http://swtbot.sourceforge.net/latest/junit/ I don't see > that org.rcpmail.test hare included in the test run. Only some tests > are included. Can you check this please? -- Ketan ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ SWTBot-users mailing list SWT...@li... https://lists.sourceforge.net/lists/listinfo/swtbot-users http://swtbot.org/ - a functional testing tool for SWT/Eclipse |
|
From: Hans S. <han...@ya...> - 2008-06-16 08:03:57
|
I don't understand what you want to tell me by that. I am willing to provide support for SWT Bot once I understood to use it. I am no information leecher. This was an extra information to you. The point is that when I start the rcpmail test, the mentioned error occurs. I compared the run configuration with the link you mentioned and see no differences. What is wrong? I simply want to start the test org.rcpmail.test As I wrote before, I start it as a SWTBot Test, as it should be. But the error occurs (see stack trace which I posted in this thread). Ketan Padegaonkar <ket...@gm...> wrote: http://swtbot.sourceforge.net/site/users-guide.html On 13-Jun-08, at 8:50 PM, Hans Schwaebli wrote: > When I start the Eclipse project "net.sf.swtbot.eclipse.ui" with > "Run as Eclipse Application" I get the same error message. There > seems to be something wrong. I compared that project (version 1.1) > against the head, but there are no changes. Is it a bug? > > On the page http://swtbot.sourceforge.net/latest/junit/ I don't see > that org.rcpmail.test hare included in the test run. Only some tests > are included. Can you check this please? -- Ketan ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ SWTBot-users mailing list SWT...@li... https://lists.sourceforge.net/lists/listinfo/swtbot-users http://swtbot.org/ - a functional testing tool for SWT/Eclipse |
|
From: Ketan P. <ket...@gm...> - 2008-06-16 03:44:26
|
Hi Paulin, My replies inline. On 16-Jun-08, at 7:45 AM, Paulin wrote: > I'm starting to play with SWT Bot and so far have found it to have > some nice features. However all the things I try to do I run into > a wall and can't get passed. I think its just because I haven't > quite figured it out but here is a short list of what I'm stuck on. There could be two reasons: a valid bug or API which does not exist :) > 1. How can I use a bot to just simulate a key press. I.E. Command > keys to make menus act, or a return key when in a text field. > 2. How do I access views menu (not the context menu) There's no API for this in the current version of SWTBot. Please file a feature request for this on http://swtbot.org/bugzilla. It's easier for me and you to track progress on new things on Bugzilla. > 3. When calling a menu > (bot.menu("Edit").menu("Preferences...").click()) it works fine, but > when doing bot.menu("WIndow").menu("Other...").click() it doesn't > find Other... I know the menu is there as I can see it on the > screen with that name. This seems like a bug. Are you able to reproduce this with the latest version nightly of SWTBot available from http://swtbot.sourceforge.net/artifacts/trunk/ ? If you're able to reproduce this, would it be possible for you to attach a screenshot of the menu bar and a stack trace on the bugzilla ? Do file individual feature/bug requests for all the above. It helps me track things better by ensuring that stuff does not slip my mind. > Thanks for the help and pointing in the right direction. > steve -- Ketan PS: You need to subscribe to the list in order to post. Subscribe here: https://lists.sourceforge.net/lists/listinfo/swtbot-users |
|
From: Ketan P. <ket...@gm...> - 2008-06-16 03:43:02
|
Hi Paulin, My replies inline. On 16-Jun-08, at 7:45 AM, Paulin wrote: > I'm starting to play with SWT Bot and so far have found it to have > some nice features. However all the things I try to do I run into > a wall and can't get passed. I think its just because I haven't > quite figured it out but here is a short list of what I'm stuck on. There could be two reasons: a valid bug or API which does not exist :) > 1. How can I use a bot to just simulate a key press. I.E. Command > keys to make menus act, or a return key when in a text field. > 2. How do I access views menu (not the context menu) There's no API for this in the current version of SWTBot. Please file a feature request for this on http://swtbot.org/bugzilla. It's easier for me and you to track progress on new things on Bugzilla. > 3. When calling a menu > (bot.menu("Edit").menu("Preferences...").click()) it works fine, but > when doing bot.menu("WIndow").menu("Other...").click() it doesn't > find Other... I know the menu is there as I can see it on the > screen with that name. This seems like a bug. Are you able to reproduce this with the latest version nightly of SWTBot available from http://swtbot.sourceforge.net/artifacts/trunk/ ? If you're able to reproduce this, would it be possible for you to attach a screenshot of the menu bar and a stack trace on the bugzilla ? Do file individual feature/bug requests for all the above. It helps me track things better by ensuring that stuff does not slip my mind. > Thanks for the help and pointing in the right direction. > steve -- Ketan |
|
From: Paulin <pa...@sp...> - 2008-06-16 02:15:43
|
I'm starting to play with SWT Bot and so far have found it to have some nice
features. However all the things I try to do I run into a wall and can't
get passed. I think its just because I haven't quite figured it out but
here is a short list of what I'm stuck on.
Backgroup:
An eclipse RCP application that has a few views, preference dialogs, and a
couple form editors.
1. How can I use a bot to just simulate a key press. I.E. Command keys to
make menus act, or a return key when in a text field.
2. How do I access views menu (not the context menu)
3. When calling a menu (bot.menu("Edit").menu("Preferences...").click()) it
works fine, but when doing bot.menu("WIndow").menu("Other...").click() it
doesn't find Other... I know the menu is there as I can see it on the
screen with that name.
Thanks for the help and pointing in the right direction.
steve
|
|
From: Ketan P. <ket...@gm...> - 2008-06-13 17:27:19
|
http://swtbot.sourceforge.net/site/users-guide.html On 13-Jun-08, at 8:50 PM, Hans Schwaebli wrote: > When I start the Eclipse project "net.sf.swtbot.eclipse.ui" with > "Run as Eclipse Application" I get the same error message. There > seems to be something wrong. I compared that project (version 1.1) > against the head, but there are no changes. Is it a bug? > > On the page http://swtbot.sourceforge.net/latest/junit/ I don't see > that org.rcpmail.test hare included in the test run. Only some tests > are included. Can you check this please? -- Ketan |
|
From: Hans S. <han...@ya...> - 2008-06-13 15:20:29
|
When I start the Eclipse project "net.sf.swtbot.eclipse.ui" with "Run as Eclipse Application" I get the same error message. There seems to be something wrong. I compared that project (version 1.1) against the head, but there are no changes. Is it a bug? On the page http://swtbot.sourceforge.net/latest/junit/ I don't see that org.rcpmail.test hare included in the test run. Only some tests are included. Can you check this please? Hans Schwaebli <han...@ya...> wrote: I thought about that too. But I got an error when running it as SWTBot Test. So I thought that might not be the right way to start them, and then I started it as a simple JUnit test, which failed. Now here is the error which I get, when starting org.rcpmail.test (compiles and org.rcpmail can be started separetely with success): java.lang.RuntimeException: Application "net.sf.swtbot.eclipse.ui.swtbottestapplication" could not be found in the registry. The applications available are: net.sf.swtbot.eclipse.headless.coretestapplication, net.sf.swtbot.eclipse.headless.swtbottestapplication, org.eclipse.ant.core.antRunner, org.eclipse.equinox.app.error, org.eclipse.jdt.apt.core.aptBuild, org.eclipse.jdt.core.JavaCodeFormatter, org.eclipse.pde.build.Build, org.eclipse.pde.junit.runtime.uitestapplication, org.eclipse.pde.junit.runtime.legacytestapplication, org.eclipse.pde.junit.runtime.coretestapplication, org.eclipse.ui.ide.workbench, org.eclipse.update.core.standaloneUpdate, org.eclipse.update.core.siteOptimizer, org.rcpmail.application. at org.eclipse.equinox.internal.app.EclipseAppContainer.startDefaultApp(EclipseAppContainer.java:242) at org.eclipse.equinox.internal.app.EclipseAppContainer.start(EclipseAppContainer.java:98) at org.eclipse.equinox.internal.app.Activator.addingService(Activator.java:112) at org.osgi.util.tracker.ServiceTracker$Tracked.trackAdding(ServiceTracker.java:1064) at org.osgi.util.tracker.ServiceTracker$Tracked.trackInitialServices(ServiceTracker.java:926) at org.osgi.util.tracker.ServiceTracker.open(ServiceTracker.java:330) at org.osgi.util.tracker.ServiceTracker.open(ServiceTracker.java:274) at org.eclipse.equinox.internal.app.Activator.start(Activator.java:54) at org.eclipse.osgi.framework.internal.core.BundleContextImpl$2.run(BundleContextImpl.java:999) at java.security.AccessController.doPrivileged(Native Method) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:993) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:974) at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:346) at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:260) at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:400) at org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:111) at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClass(ClasspathManager.java:417) at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.findLocalClass(DefaultClassLoader.java:189) at org.eclipse.osgi.framework.internal.core.BundleLoader.findLocalClass(BundleLoader.java:340) at org.eclipse.osgi.framework.internal.core.SingleSourcePackage.loadClass(SingleSourcePackage.java:37) at org.eclipse.osgi.framework.internal.core.BundleLoader.findClassInternal(BundleLoader.java:405) at org.eclipse.osgi.framework.internal.core.BundleLoader.findClass(BundleLoader.java:369) at org.eclipse.osgi.framework.internal.core.BundleLoader.findClass(BundleLoader.java:357) at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:83) at java.lang.ClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClassInternal(Unknown Source) at org.eclipse.core.internal.runtime.PlatformActivator.startAppContainer(PlatformActivator.java:47) at org.eclipse.core.internal.runtime.PlatformActivator.start(PlatformActivator.java:32) at org.eclipse.osgi.framework.internal.core.BundleContextImpl$2.run(BundleContextImpl.java:999) at java.security.AccessController.doPrivileged(Native Method) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:993) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:974) at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:346) at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:350) at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1118) at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:634) at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:508) at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:282) at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:468) at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:195) at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:297) eclipse.buildId=M20080221-1800 java.version=1.6.0_06 java.vendor=Sun Microsystems Inc. BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=de_DE Framework arguments: -version 3 -port 3300 -testLoaderClass org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestLoader -loaderpluginname org.eclipse.jdt.junit.runtime -testNameFile C:\DOKUME~1\markovze\LOKALE~1\Temp\testNames64035.txt -application net.sf.swtbot.eclipse.ui.swtbottestapplication -product org.eclipse.sdk.ide -pdelaunch -testpluginname org.rcpmail.test Command-line arguments: -os win32 -ws win32 -arch x86 -version 3 -port 3300 -testLoaderClass org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestLoader -loaderpluginname org.eclipse.jdt.junit.runtime -testNameFile C:\DOKUME~1\markovze\LOKALE~1\Temp\testNames64035.txt -application net.sf.swtbot.eclipse.ui.swtbottestapplication -product org.eclipse.sdk.ide -data C:\eclipse\workspace/../junit-workspace -dev file:C:/eclipse/workspace/.metadata/.plugins/org.eclipse.pde.core/pde-junit/dev.properties -pdelaunch -os win32 -ws win32 -arch x86 -testpluginname org.rcpmail.test Ketan Padegaonkar <ket...@gm...> wrote: On 13-Jun-08, at 11:17 AM, Hans Schwaebli wrote: > at junit.framework.TestSuite.runTest(TestSuite.java:230) > at junit.framework.TestSuite.run(TestSuite.java:225) > at > org > .eclipse > .jdt > .internal > .junit > .runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130) > at > org > .eclipse > .jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) > at > org > .eclipse > .jdt > .internal > .junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460) You seem to be running this as a JUnit test instead of an SWTBot test. There's a right click option to run as SWTBot test. -- Ketan ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ SWTBot-users mailing list SWT...@li... https://lists.sourceforge.net/lists/listinfo/swtbot-users http://swtbot.org/ - a functional testing tool for SWT/Eclipse ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php_______________________________________________ SWTBot-users mailing list SWT...@li... https://lists.sourceforge.net/lists/listinfo/swtbot-users http://swtbot.org/ - a functional testing tool for SWT/Eclipse |