uispec4j

UISpec4J Capturing modal dialog, before the trigger finish

本小妞迷上赌 提交于 2019-12-24 12:35:13
问题 I have some code where I'm showing up a dialog with two textboxes and two buttons (as OK, and Cancel, typical login window). The execution of the main code after the ".setVisible(true)" is conditioned to the values entered on that modal window. The problem that I'm facing now is that if I do something like this: WindowInterceptor.init(new Trigger() { @Override public void run() throws Exception { LoginModal loginWin=new LoginModal(); loginWin.setVisible(true); if(loginWin.getPassword().equals

Getting all windows using UISpec4J

試著忘記壹切 提交于 2019-12-08 09:56:34
问题 I am trying to use UISpec4J in order to automate a Java Swing application. After adapter setup: setAdapter(new MainClassAdapter(Main.class, new String[0])); I am trying to obtain the main window: Window mainWindow = getMainWindow(); Instead of a login dialog, I am getting a splash screen with logo of application. All my attempts to call this dialog manually have failed. How can I get the list of opened dialogs/windows? 回答1: It looks like MainClassAdapter is not designed to handle a sequence