swtbot

SWTBot test outside Eclipse application

旧时模样 提交于 2020-01-24 10:09:27
问题 I have an application that can run as a regular Eclipse plug-in, and I can test it with my SWTBot tests as usual. The same plug-in application can be installed separately on my computer (like any other windows application). The question is - How can I configure the SWTBot tests to run on the separately installed application? (Instead of class name I need to use some folder/file name as the application place). 回答1: You'll need to install SWTBot in your target application in one way or the

Programmatically resize a view in Eclipse

我只是一个虾纸丫 提交于 2019-12-23 19:01:43
问题 I'm testing an non-e4 RCP application using SWTBot and I need to change the size of my view. (Move the sash-bar) I unsuccessfully tried Resize my view using SWTBot (no such api) Resize my view using Eclipse 3 API (no supported) Resize my view using underlying e4 model (resizing not working) e4 model seams to be promising, but I'm missing something, so it doesn't work. I can Get MPart of my view: view = ePartService.findPart(ID) Get MTrimmedWindow: window = (view as EObject).eContainer as

How to integrate cucumber-jvm with maven build

怎甘沉沦 提交于 2019-12-10 12:20:07
问题 i'm trying to put some bdd into my eclipse plugin project, but can't figure out how to run my integration tests during maven build fase. To write my tests i'm using SWTBot framework. I already did the feature generation fase, and setup my tests. How do i setup my pom to run my integration tests? 回答1: I use below configuration and run mvn clean verify . If you don't want to run tests in parallel, remove parallel , perCoreThreadCount and threadCountClasses tags. Make sure to update the regular

“An unexpected error occured (return code -1)” when trying to launch SWTBot test suite with Tycho

走远了吗. 提交于 2019-12-08 11:52:30
问题 We are writing SWTBot tests for our Eclipse RCP application. Our RCP application includes NatTable components and has authorization mechanism to enable/disable perspectives. The test suite is working fine when launching it from Eclipse. Now we are trying to integrate it with Tycho. This is the pom.xml created for running the SWTBot test suite: <?xml version="1.0" encoding="UTF-8"?> <project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"

How to add the plugin with my RCP application in the Tycho SWTBot test runtime

烂漫一生 提交于 2019-12-01 18:32:03
问题 My RCP was created on a 3.x Eclipse and is now on 4.x using the compatibility layer. This is the setup that I have: I have two plugins: xyz-plugin and xyz-rcp-plugin . My RCP application is composed of these two plugins. I have a Test fragment ( xyz-test ) whose host plugin is xyz-plugin and contains SWTBot tests. My product configuration points to the application defined in the plugin.xml of xyz-rcp-plugin . When I run the SWTBot Test via Eclipse, it all works ok. I point it to the correct

How to add the plugin with my RCP application in the Tycho SWTBot test runtime

穿精又带淫゛_ 提交于 2019-12-01 17:54:26
My RCP was created on a 3.x Eclipse and is now on 4.x using the compatibility layer. This is the setup that I have: I have two plugins: xyz-plugin and xyz-rcp-plugin . My RCP application is composed of these two plugins. I have a Test fragment ( xyz-test ) whose host plugin is xyz-plugin and contains SWTBot tests. My product configuration points to the application defined in the plugin.xml of xyz-rcp-plugin . When I run the SWTBot Test via Eclipse, it all works ok. I point it to the correct application on the Main tab and it launches the correct one. When I try to run it via Maven (using mvn

Testing SWT GUI with SWTBot

余生长醉 提交于 2019-11-30 15:23:03
问题 I want to test a simple SWT GUI application with SWTBot. Unfortunatly, I have no idea how to start. There are several tutorials which describe the testing of an Eclipse plug-in but I could not find anything regarding my problem. I don't even know if it is possible. 回答1: Well it is very much possible. Follow the step as mentioned below. Download SWTBot for SWT Testing Put it in the <eclipsehome>/dropins folder Restart your eclipse Now at this point you are ready to play with SWTBot . For the