Skip to Main Content
Cucumber Recipes
book

Cucumber Recipes

by Ian Dees, Matt Wynne, Aslak Hellesoy
February 2013
Intermediate to advanced content levelIntermediate to advanced
272 pages
5h 45m
English
Pragmatic Bookshelf
Content preview from Cucumber Recipes
Recipe 22Drive a Swing Interface with FEST

Problem

You want to test a Java program with a user interface implemented in Swing.

Ingredients

  • 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

Solution

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 ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Cucumber Cookbook

Cucumber Cookbook

Shankar Garg
Basiswissen Softwaretest , 6th Edition

Basiswissen Softwaretest , 6th Edition

Andreas Spillner, Tilo Linz
React Cookbook

React Cookbook

David Griffiths, Dawn Griffiths

Publisher Resources

ISBN: 9781941222607Errata