Questions tagged [fest]

FEST (Fixtures for Easy Software Testing) is a collection of APIs to facilitate Java software testing. FEST contains a fluent API for reflection, assertion and interacting with SWING GUI Components. It can be used within JUnit and TestNG.

See the FEST home page.

91 questions
3
votes
1 answer

Android Testing java.lang.NoClassDefFoundError Error due to Fest-Android

I'm currently implementing Fest for Android into my project but I seem to be running into a dependency issue. If I run my tests without the Fest library included, the tests will run as normal. Once I add in the Fest library then the tests no longer…
3
votes
0 answers

JAVA FEST Can't find OptionsPane

I am trying to get Java FEST to find a pop up dialogue and click on the the yes button. I have the following code: JOptionPaneFixture fixture = JOptionPaneFinder.findOptionPane().using(TestSite.myRobot); fixture.buttonWithText("Yes" ).click(); On…
whomaniac
  • 1,258
  • 4
  • 15
  • 22
2
votes
3 answers

Thread.sleep(time) vs. robot.wait(time)

I'm trying to write some GUI and integration tests using JUnit and FEST. Here is what I have: @Before public void setUp(){ try{ program.main(args); robot.wait(30000); //gives IllegalMonitorStateException …
user793623
2
votes
1 answer

Are there any sample GUI and FEST code that might help in understanding the framework?

I have been reading a lot and looking at the code to understand how FEST works. Unforunately I could'n find that many sample code online other…
user793623
2
votes
2 answers

FEST: Assert that JButton is showing a certain Icon

In my FEST-Test I try to assert, that a JButton has a certain ImageIcon. I didn't find a corresponding method on org.fest.swing.fixture.JButtonFixture
keuleJ
  • 3,418
  • 4
  • 30
  • 51
2
votes
1 answer

FEST JUnit-Swing testing noobQ: how to test a main class?

Despite reading the tutorial here, I cant seem to understand how to make FEST work with my application. I have a Swing application in a big class witht a main method, and a couple of SwingWorker classes. I want to test my application as if I'm…
Soroush Hakami
  • 5,226
  • 15
  • 66
  • 99
2
votes
2 answers

Multiple JUnit tests using FEST

I've written several JUnit test methods to test my Java Swing GUI (using FEST). My class is in the following format: public class Tests { @BeforeClass public static void beforeClass() throws Exception { ... } @Before public void…
Tom W
  • 578
  • 6
  • 16
2
votes
1 answer

Attaching FEST to an Application

Is there a way to attach a FEST test to a previously started Application instead of starting the application from the test? I'm asking this because Squish for example can do this. I couldn't find anything similar for FEST. This question comes from…
Vlad Topala
  • 896
  • 1
  • 8
  • 34
2
votes
1 answer

Groovy closure to implement matcher in Fest

I am trying to create a closure matcher for Fest with Groovy (2.1.6) like this: def matcherLabel = [ isMatching: { JLabel label -> /* do something */ } ] as GenericTypeMatcher GenericTypeMatcher is an abstract class with one method only to…
Randomize
  • 8,651
  • 18
  • 78
  • 133
2
votes
0 answers

How to automate java applet using fest java?

I spent almost entire day on finding the answer of this question. I came to know that I can do this using Fest. I tried to understand how to do it using fest, but unable to understand it. There are not much tutorial available on fest. So can anyone…
narayanpatra
  • 5,627
  • 13
  • 51
  • 60
2
votes
2 answers

FEST Test hangs on creating new Robot

I'm trying to run tests on multiple frames. When executed it hangs on the creation of a new Robot. The first frame uses the default Robot, the code for the second Robot is below: Robot robot2 = BasicRobot.robotWithCurrentAwtHierarchy(); window2 =…
John Smith
  • 276
  • 1
  • 2
  • 15
2
votes
2 answers

Correct way of using FEST-assert in Junit for Android?

I'm new to both JUnit and FEST on Android. I'm trying to use FEST-Android in my class but keep getting error when compile: Android Dex: [ZHoltoTest] trouble processing "javax/xml/parsers/DocumentBuilder.class": Android Dex: [ZHoltoTest] Ill-advised…
RobGThai
  • 5,937
  • 8
  • 41
  • 59
2
votes
1 answer

JMockit and Fest UI testing

I have been working on a project that has numerous UI components. Since all the components are based on the MVC pattern, they are structured as a component - public interface and factory, package protected model/view/controller. Testing them "by…
pfh
  • 530
  • 1
  • 9
  • 24
2
votes
3 answers

ClassNotFound error when building Fest with maven

Would like to try out fest 2.x branch. I'm not familiar with maven, but I downloaded fest from github, which gave me a pom.xml, so I ran maven with mvn install, and get the following: [INFO] Error stacktraces are turned on. [INFO] Scanning for…
Sam Barnum
  • 10,559
  • 3
  • 54
  • 60
2
votes
1 answer

FEST: Wait for the GUI to load before doing anything

@Before public void setUp() { Robot robot = BasicRobot.robotWithCurrentAwtHierarchy(); ApplicationLauncher.application("myApp").start(); Pause.pause(5, TimeUnit.SECONDS); frame =…
Whimusical
  • 6,401
  • 11
  • 62
  • 105