io.magentys.fest.SwingAppDriver Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cherry-fest Show documentation
Show all versions of cherry-fest Show documentation
Integrate Fest Swing App Testing framework with Cherry
package io.magentys.fest;
import org.assertj.swing.core.BasicRobot;
import org.assertj.swing.core.Robot;
import org.assertj.swing.edt.GuiActionRunner;
import org.assertj.swing.edt.GuiTask;
public class SwingAppDriver {
private Robot robot;
private boolean isRunning;
private Long defaultWaitingTimeout = 60000L;
public void setRunningTo(boolean isRunning) {
this.isRunning = isRunning;
}
public Robot robot() {
return robot;
}
public void setRobot(Robot robot) {
this.robot = robot;
}
public boolean isRunning() {
return isRunning;
}
public SwingAppDriver init(GuiTask guiTask){
GuiActionRunner.execute(guiTask);
robot = BasicRobot.robotWithCurrentAwtHierarchy();
return this;
}
public Long getDefaultWaitingTimeout() {
return defaultWaitingTimeout;
}
public void setDefaultWaitingTimeout(Long defaultWaitingTimeout) {
this.defaultWaitingTimeout = defaultWaitingTimeout;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy