Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "Eclipse 4diacWiki/Development/User Interface Quality Improvement"

(Merge edit by Andrea.f.zoitl.gmail.com)
Line 1: Line 1:
=== Topic ===
+
= Eclipse 4diac IDE User Interface Quality Improvement Through Automated Testing =
Eclipse 4diac IDE User Interface Quality Improvement Through Automated Testing
+
  
Often open source projects have only a few contributors. These try to incorporate all new ideas and improvements. However, this leaves little time for testing, which means that the software quality suffers. Since Eclipse 4diac is also still tested manually, which on the one hand is inefficient and on the other hand is often not performed completely due to time constraints. For this reason, an automated test set for the 4diac IDE user interface would be a good improvement.
+
== Project Goals ==
 +
Often, open source projects have only a few contributors. These try to incorporate all new ideas and
 +
improvements. However, this leaves little time for testing, which means that the software quality
 +
suffers.
 +
Since Eclipse 4diac is also still tested manually, which on the one hand is inefficient and on the
 +
other hand is often not performed completely due to time constraints. For this reason, an automated
 +
test set for the 4diac IDE user interface would be a good improvement.
 +
 
 +
== Development Process ==
 +
For this purpose, various options that are available so that the tests can be automated are reviewed.
 +
In order to understand Eclipse 4diac IDE and to become familiar with the program, the tutorial was worked through first.
 +
This is essential in order to be able to work out suitable test cases.
 +
 
 +
=== Eclipse RCP Testing Tool ===
 +
After reading the documentation of RCPTT, I installed the program with the latest release version. Unfortunately, it did not work to add 4diac IDE Nightly as AUT (application-under-test).
 +
More attempts were made, but the only combination that worked was RCPTT Nightly with 4diac IDE stable version. Since the preference is to test the nightly built version of 4diac IDE, the RCPTT was not continued for the time being.
 +
 
 +
=== Eclipse SWTBot ===
 +
I have read the documentation and then installed the program. After the setup, the first basic tests are running and it looks promising.
 +
 
 +
The first test set includes checking if a 4diac IDE project can be created, if it can be deleted afterwards and if it is not possible to create 2 projects with the same name as expected.
 +
 
 +
An important step for the project was to be able to drag and drop FBs from the System Explorer to the Editor Area. Initial tests have shown that this is possible, including placing them on a desired position. To achieve this, it was necessary to switch from SWTWorkbenchBot to SWTGefBot which extends the former.
 +
 
 +
Dragging a connection was a challenge because the provided dragAndDrop method selects a pin and then jumps to the other pin with the mouse button held down. But 4diac needs a mouse movement to get from the view mode to the connections drag mode. For this reason, it became necessary to write own classes which respond to the characteristics of 4diac.
 +
 
 +
The 4 classes are SWT4diacGefBot extends SWTGefBot, SWTBot4diacGefEditor extends SWTBotGefEditor, SWTBot4diacGefViewer extends SWTBotGefViewer and SWTBot4diacFigureCanvas extends SWTBotGefFigureCanvas. The overwritten method mouseDrag of the class SWTBot4diacFigureCanvas adds the necessary mouse movement, and also the necessary changes of the calling classes were made.
 +
 
 +
Thus, it is possible to draw a connection between 2 FBs. Initial tests have shown that multiple FBs can be dragged and dropped into the Editor Area and connections can be created.
 +
 
 +
This knowledge is a good starting point to create a test set that can be implemented.
 +
 
 +
'''Important:''' It has been noticed that while the tests are being performed automatically, you are not allowed to click the mouse manually, as this will cause the tests to fail.
 +
 
 +
== Development of the test case set ==
 +
tba
 +
 
 +
Contributor: Andrea Zoitl
  
Contributer: Andrea Zoitl
 
 
Timeline: May - November 2023
 
Timeline: May - November 2023

Revision as of 07:57, 25 August 2023

Eclipse 4diac IDE User Interface Quality Improvement Through Automated Testing

Project Goals

Often, open source projects have only a few contributors. These try to incorporate all new ideas and improvements. However, this leaves little time for testing, which means that the software quality suffers. Since Eclipse 4diac is also still tested manually, which on the one hand is inefficient and on the other hand is often not performed completely due to time constraints. For this reason, an automated test set for the 4diac IDE user interface would be a good improvement.

Development Process

For this purpose, various options that are available so that the tests can be automated are reviewed. In order to understand Eclipse 4diac IDE and to become familiar with the program, the tutorial was worked through first. This is essential in order to be able to work out suitable test cases.

Eclipse RCP Testing Tool

After reading the documentation of RCPTT, I installed the program with the latest release version. Unfortunately, it did not work to add 4diac IDE Nightly as AUT (application-under-test). More attempts were made, but the only combination that worked was RCPTT Nightly with 4diac IDE stable version. Since the preference is to test the nightly built version of 4diac IDE, the RCPTT was not continued for the time being.

Eclipse SWTBot

I have read the documentation and then installed the program. After the setup, the first basic tests are running and it looks promising.

The first test set includes checking if a 4diac IDE project can be created, if it can be deleted afterwards and if it is not possible to create 2 projects with the same name as expected.

An important step for the project was to be able to drag and drop FBs from the System Explorer to the Editor Area. Initial tests have shown that this is possible, including placing them on a desired position. To achieve this, it was necessary to switch from SWTWorkbenchBot to SWTGefBot which extends the former.

Dragging a connection was a challenge because the provided dragAndDrop method selects a pin and then jumps to the other pin with the mouse button held down. But 4diac needs a mouse movement to get from the view mode to the connections drag mode. For this reason, it became necessary to write own classes which respond to the characteristics of 4diac.

The 4 classes are SWT4diacGefBot extends SWTGefBot, SWTBot4diacGefEditor extends SWTBotGefEditor, SWTBot4diacGefViewer extends SWTBotGefViewer and SWTBot4diacFigureCanvas extends SWTBotGefFigureCanvas. The overwritten method mouseDrag of the class SWTBot4diacFigureCanvas adds the necessary mouse movement, and also the necessary changes of the calling classes were made.

Thus, it is possible to draw a connection between 2 FBs. Initial tests have shown that multiple FBs can be dragged and dropped into the Editor Area and connections can be created.

This knowledge is a good starting point to create a test set that can be implemented.

Important: It has been noticed that while the tests are being performed automatically, you are not allowed to click the mouse manually, as this will cause the tests to fail.

Development of the test case set

tba

Contributor: Andrea Zoitl

Timeline: May - November 2023

Back to the top