Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » SWTBot » Can SWTBot support pure SWT application(I'm going to test an application which was created using SWT rather than Eclipse. I wander if I can use SWTBot for the test.)
Can SWTBot support pure SWT application [message #869764] Fri, 04 May 2012 09:01 Go to next message
kyle yu is currently offline kyle yuFriend
Messages: 1
Registered: May 2012
Junior Member
Dear all,

I'm going to test an application which was created using SWT rather than Eclipse. I wander if I can use SWTBot for the test.
I searched SWTBot user guide and sample code. All I get were for Eclipse based application.
Anyone can help me? Thanks in advance!
Re: Can SWTBot support pure SWT application [message #887212 is a reply to message #869764] Sat, 16 June 2012 07:57 Go to previous messageGo to next message
Timur Achmetow is currently offline Timur AchmetowFriend
Messages: 38
Registered: April 2012
Member
Yes! You have to install the feature "SWTBot SWT Features" which includes SWTBot for SWT Testing.
Re: Can SWTBot support pure SWT application [message #898955 is a reply to message #869764] Sun, 29 July 2012 10:17 Go to previous messageGo to next message
Wolfgang Martin is currently offline Wolfgang MartinFriend
Messages: 1
Registered: July 2012
Junior Member
I have a similar situation: I want to test a desktop application that uses the SWT library but none of the other eclipse features. I want to be completely independent from eclipse. Let's assume that I'm developing in Netbeans.

So:
* the application under test uses the SWT jar, but not RCP, the eclipse workbench
* I can't install eclipse features because I'm not using eclipse, at all.
* I want to run the tests independently from the IDE.

Also: I can't use a special TestRunner because I'm already using another one to support another library I'm using. So, @RunWith is not possible for me.
Re: Can SWTBot support pure SWT application [message #899341 is a reply to message #898955] Tue, 31 July 2012 13:59 Go to previous message
Mickael Istria is currently offline Mickael IstriaFriend
Messages: 771
Registered: July 2009
Location: Grenoble, France
Senior Member
On 07/29/2012 12:17 PM, Wolfgang Martin wrote:
> So:
> * the application under test uses the SWT jar, but not RCP, the eclipse
> workbench

The SWT part of SWTBot is independant from workbench and RCP. You can
use it in any SWT application.

> * I can't install eclipse features because I'm not using eclipse, at all.

Can you downalod the following jars and put them into your application
to use SWTBot:
*
http://download.eclipse.org/technology/swtbot/helios/dev-build/update-site/plugins/org.eclipse.swtbot.swt.finder_2.0.5.20111003_1754-3676ac8-dev-e36.jar
*
http://download.eclipse.org/technology/swtbot/helios/dev-build/update-site/plugins/org.apache.log4j_1.2.13.v200903072027.jar
*
http://download.eclipse.org/technology/swtbot/helios/dev-build/update-site/plugins/org.eclipse.swtbot.junit4_x_2.0.5.20111003_1754-3676ac8-dev-e36.jar
*
http://download.eclipse.org/technology/swtbot/helios/dev-build/update-site/plugins/org.hamcrest_1.1.0.v20090501071000.jar
*
http://download.eclipse.org/technology/swtbot/helios/dev-build/update-site/plugins/org.hamcrest.core_1.1.0.v20090501071000.jar
*
http://download.eclipse.org/technology/swtbot/helios/dev-build/update-site/plugins/org.hamcrest.library_1.1.0.v20090501071000.jar
*
http://download.eclipse.org/technology/swtbot/helios/dev-build/update-site/plugins/org.hamcrest.text_1.1.0.v20090501071000.jar
*
http://download.eclipse.org/technology/swtbot/helios/dev-build/update-site/plugins/org.hamcrest.integration_1.1.0.v20090501071000.jar

Feel free to open an enhancement request if you'd like to see a more
convenient packaging appear one day.

> * I want to run the tests independently from the IDE.

SWTBot is just an API on top of SWT, it's independant of JUnit or the
IDE you use. So no problem here.

> Also: I can't use a special TestRunner because I'm already using another
> one to support another library I'm using. So, @RunWith is not possible
> for me.

Using SWTBot TestRunner is not necessary, you can use a plain JUnit test.


--
Mickael Istria
JBoss, by Red Hat
My blog: http://mickaelistria.wordpress.com
My Tweets: http://twitter.com/mickaelistria
Previous Topic:SWTBot/Contributing
Next Topic:SWTBot with e4 product
Goto Forum:
  


Current Time: Sun Dec 21 05:41:53 GMT 2014

Powered by FUDForum. Page generated in 0.06749 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software