Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 564849 - [Tests] Some debug tests are unstable
Summary: [Tests] Some debug tests are unstable
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Debug (show other bugs)
Version: 4.17   Edit
Hardware: All All
: P3 minor (vote)
Target Milestone: 4.18   Edit
Assignee: Paul Pazderski CLA
QA Contact:
URL:
Whiteboard: 4.17 M2
Keywords:
Depends on:
Blocks:
 
Reported: 2020-07-01 14:48 EDT by Paul Pazderski CLA
Modified: 2020-11-17 00:21 EST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Paul Pazderski CLA 2020-07-01 14:48:34 EDT
I noticed some minor issues in my recently added JUnit tests.

OutputStreamMonitorTests
  Two of the tests are explicit written for UTF-8 but the monitor is initialized with default charset. Since many modern systems use UTF-8 as default the test still works most of the times.

InputStreamMonitorTests
  The closing test stops the input monitoring thread and immediately checks if the thread is stopped. I saw a few random test failures locally from this race condition.

BreakpointTests
  Calling dispose on a view is not the right way to close the view. I admit this one was a bit stupid.
Comment 1 Eclipse Genie CLA 2020-07-01 14:49:37 EDT
New Gerrit change created: https://git.eclipse.org/r/c/platform/eclipse.platform.debug/+/165705
Comment 3 Sarika Sinha CLA 2020-07-04 11:47:09 EDT
We still see one failure.
https://download.eclipse.org/eclipse/downloads/drops4/I20200703-1800/testresults/html/org.eclipse.debug.tests_ep417I-unit-win32-java11_win32.win32.x86_64_11.html

testBug424561_undoRedoUndoGone	Failure	Breakpoint is not deleted

java.lang.AssertionError: Breakpoint is not deleted
at org.junit.Assert.fail(Assert.java:89)
at org.eclipse.debug.tests.TestUtil.waitWhile(TestUtil.java:134)
at org.eclipse.debug.tests.breakpoint.BreakpointTests.testBug424561_undoRedoUndoGone(BreakpointTests.java:110)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
Comment 4 Paul Pazderski CLA 2020-07-04 17:26:47 EDT
Did not failed with I20200704-0600. But testRedirectOutputToFile	Failure	Output not found in console. expected:<[Hello World!]> but was:<[]>

org.junit.ComparisonFailure: Output not found in console. expected:<[Hello World!]> but was:<[]>
at org.junit.Assert.assertEquals(Assert.java:117)
at org.eclipse.debug.tests.console.ProcessConsoleTests.doConsoleOutputTest(ProcessConsoleTests.java:400)
at org.eclipse.debug.tests.console.ProcessConsoleTests.testRedirectOutputToFile(ProcessConsoleTests.java:302)


Will see if I can find the reason for the instability of both...
Comment 6 Sarika Sinha CLA 2020-07-17 01:47:58 EDT
Not seeing any failure in recent builds.
Comment 7 Sarika Sinha CLA 2020-08-14 01:27:50 EDT
We have failure today 
https://download.eclipse.org/eclipse/downloads/drops4/I20200813-1800/testresults/html/org.eclipse.debug.tests_ep417I-unit-cen64-gtk3-java11_linux.gtk.x86_64_11.html

https://download.eclipse.org/eclipse/downloads/drops4/I20200813-1800/testresults/html/org.eclipse.debug.tests_ep417I-unit-cen64-gtk3-java14_linux.gtk.x86_64_14.html

testNullCharset	Failure	Monitor read wrong content. expected:<o[öOïiIÖØø]> but was:<o[?O?iI???]>

org.junit.ComparisonFailure: Monitor read wrong content. expected:<o[öOïiIÖØø]> but was:<o[?O?iI???]>
at org.junit.Assert.assertEquals(Assert.java:117)
at org.eclipse.debug.tests.console.OutputStreamMonitorTests.testNullCharset(OutputStreamMonitorTests.java:181)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

testNullCharset	Failure	Monitor wrote wrong content. expected:<o[öOïiIÖØø]> but was:<o[?O?iI???]>

org.junit.ComparisonFailure: Monitor wrote wrong content. expected:<o[öOïiIÖØø]> but was:<o[?O?iI???]>
at org.junit.Assert.assertEquals(Assert.java:117)
at org.eclipse.debug.tests.console.InputStreamMonitorTests.testNullCharset(InputStreamMonitorTests.java:87)
Comment 8 Sarika Sinha CLA 2020-08-17 06:56:23 EDT
It is consistently failing since last few days.
@Paul,
Can you look into this?
https://download.eclipse.org/eclipse/downloads/drops4/I20200816-0600/testresults/html/org.eclipse.debug.tests_ep417I-unit-cen64-gtk3-java11_linux.gtk.x86_64_11.html
Comment 9 Sarika Sinha CLA 2020-11-17 00:21:35 EST
Did not see it happen in 4.18 timeframe.