Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clicking and typing work very slow #201

Closed
otrebski opened this issue Mar 11, 2017 · 2 comments
Closed

Clicking and typing work very slow #201

otrebski opened this issue Mar 11, 2017 · 2 comments

Comments

@otrebski
Copy link

I have created simple UI test as proof of concept: https://github.com/otros-systems/otroslogviewer/blob/ui_test_poc/OtrosLogViewer-app/src/test/java/scenario/ExampleUiTest.java

I'm running test with gradle (or IntellJ):

git clone https://github.com/otros-systems/otroslogviewer.git
git checkout ui_test_poc
./gradlew -Dtest.single=\*ExampleUiTest   OtrosLogViewer-app:test

Clicking and typing takes a long time. This simple test (open application, click 2 buttons, type 30 chars) takes 100 seconds.

Tested with:
org.assertj:assertj-core:3.6.2
org.assertj:assertj-swing-testng:3.5.0
org.testng:testng:6.8.8
Linux and OSX
Java 8

@otrebski
Copy link
Author

I have found out that I'm using custom event queue #13
Solution is to run application (for testing) without custom event queue. It works in my context.

@fredand44
Copy link

Hello Otrebski,

I experience the same problem, could you please explain how you implemented the solution without a custom event queue?
In my case, I try to click a menuItem, but it takes like over 20 sec.

First I thought it was something of how the component was located, but it seems like it is the "click" that's take time.

public void theUserClickTheMenuItem( String menuItemName ) throws Throwable
{
	JMenuItemFixture menuItem = frameFixture.menuItem( menuItemName );
	System.out.println( "FIND DONE!" );
	assertNotNull( menuItem );
	System.out.println( "ASSERT DONE!" );
	menuItem.click();
	System.out.println( "CLICK DONE!" );	
}

Best regards
Fredrik

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants