Community
Participate
Working Groups
LabelProviderTest.testOverrideChain fails consistently on Windows 7 and Linux. Wrong query order for text junit.framework.AssertionFailedError: Wrong query order for text at org.eclipse.ui.tests.navigator.LabelProviderTest.testOverrideChain(LabelProviderTest.java:233) at org.eclipse.test.EclipseTestRunner.run(EclipseTestRunner.java:657) at org.eclipse.test.EclipseTestRunner.run(EclipseTestRunner.java:310) at org.eclipse.test.UITestApplication$2.run(UITestApplication.java:197) at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35) at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:136) at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:4147) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3764) at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1135) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1016) at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:148) at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:635) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:578) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150) at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:135) at org.eclipse.test.UITestApplication.runApplication(UITestApplication.java:140) at org.eclipse.test.UITestApplication.run(UITestApplication.java:62) at org.eclipse.test.UITestApplication.start(UITestApplication.java:212) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:379) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:233) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:648) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:603) at org.eclipse.equinox.launcher.Main.run(Main.java:1465) at org.eclipse.equinox.launcher.Main.main(Main.java:1438) at org.eclipse.core.launcher.Main.main(Main.java:34)
This passes for me on linux with 1.7.0_51, but failes with 1.8. I'll investigate further. PW
In my environment (Windows 7 x64) it fails only with Java 8.
(In reply to Wojciech Sudol from comment #2) > In my environment (Windows 7 x64) it fails only with Java 8. Correct, that's the same problem I have. The question is why? PW
The test fails with Java 8 because of changes in HashMap implementation. These changes affects the order of elements returned by NavigatorContentService.findPossibleLabelExtensions(Object). However it is not clear if the 'new' order is incorrect. The javadoc comments are not precise enough. I will try to find more information about this functionality and determine expected result.
(In reply to Wojciech Sudol from comment #4) > The test fails with Java 8 because of changes in HashMap implementation. In case the current order is correct, just use org.eclipse.test.OrderedTestSuite.
Francis, I'm looking at this failure with java 8 and the question I had was, what order does overrides/@suppressedExtensionId guarantee? I'm just guessing that the extensions are all sorted by priority (high to low) and then extensions get to go before their suppressed extensions, right? PW
OK, we have: A - normal B - normal - override: A C - low - override: A D - low - override: B E - low - override: D F - high - override: C G - normal - override: C If I sort them into buckets, I get: high : F normal: A B G low : C D E Now I assume that the overrides will move the label providers before the extension being overridden. But within a group there's no order, so there's a couple of ways that can be accomplished. This seems valid to me: F G E D BC A The test asks for FEDBGCA PW
Released fix as http://git.eclipse.org/c/platform/eclipse.platform.ui.git/commit/?id=cf9d93f38aeede6d0315505dc3072c0df583e272 PW
Sorry Paul, I have forgotten most of that stuff, even though I'm still on the list. Maybe one day I can come back. What you have seems right though.
(In reply to Francis Upton IV from comment #9) > Sorry Paul, I have forgotten most of that stuff, even though I'm still on > the list. Maybe one day I can come back. What you have seems right though. Thanks for getting back to me :-) PW
verified in http://download.eclipse.org/eclipse/downloads/drops4/I20140501-0200/testResults.php PW