February 2013
Intermediate to advanced
272 pages
5h 45m
English
| Recipe 22 | Drive a Swing Interface with FEST |
You want to test a Java program with a user interface implemented in Swing.
JRuby,[135] a pure-Java implementation of Ruby
FEST,[136] a Java library for driving Swing GUIs
PresentationClock,[137] the example Java app we’ll be testing
The Java testing community has created an amazing number of GUI automation libraries. They vary based on the type of user interfaces they can automate—Swing, SWT, JavaFX, and so on.
For this recipe, you’ll be testing PresentationClock, a simple Swing app. The FEST automation library is a good fit for driving this program: it’s actively maintained, well-documented,[138] and relatively easy to use.
You can operate FEST from Java using Cucumber-JVM ...