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

Random failing LargeFileTest #2622

Open
jukzi opened this issue Dec 12, 2024 · 2 comments
Open

Random failing LargeFileTest #2622

jukzi opened this issue Dec 12, 2024 · 2 comments
Labels
good first issue Good for newcomers test junit test related things

Comments

@jukzi
Copy link
Contributor

jukzi commented Dec 12, 2024

https://download.eclipse.org/eclipse/downloads/drops4/I20241211-1800/testresults/html/org.eclipse.ui.editors.tests_ep435I-unit-macosx-x86_64-java17_macosx.cocoa.x86_64_17.html

java.lang.AssertionError: Opening large file took too long: 644.8726ms with marker vs. 306.91605ms without
at org.junit.Assert.fail(Assert.java:89)
at org.junit.Assert.assertTrue(Assert.java:42)
at org.eclipse.ui.editors.tests.LargeFileTest.openLargeFileWithAnnotation(LargeFileTest.java:135)
at java.base/java.lang.reflect.Method.invoke(Method.java:568)

cc at author of that test: @tomaswolf
maybe just increase timeout?

@jukzi jukzi added good first issue Good for newcomers test junit test related things labels Dec 12, 2024
@tomaswolf
Copy link
Member

I thought a factor of 2 was already rather generous. Apparently not. In the bug report linked in the commit message when that test was created, the UI freeze was 15sec.

As the comment in the test class says, all this timing is very approximate. So either use a larger factor, or come up with a better way to test for this, or investigate why opening the file with a single marker takes more than twice as long, and then improve that to be not that slow.

@jukzi
Copy link
Contributor Author

jukzi commented Dec 12, 2024

Performance tests using the clock time have not been shown successful with our build infrastructure as the machines tend to have to much jitter in their performance.
If the build machine pauses for a second for unkknown reasons it is totally unrelated to the code tested.
Time should only be used as timeout after a few seconds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers test junit test related things
Projects
None yet
Development

No branches or pull requests

2 participants