Bug 296805

Summary: 2 test failures in HistoryStoreTest on RHEL 4u8 32-bit / Sun 1.5.0_20
Product: [Eclipse Project] Platform Reporter: Martin Oberhuber <mober.at+eclipse>
Component: ResourcesAssignee: John Arthorne <john.arthorne>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: daniel_megert, john.arthorne, Szymon.Brandys
Version: 3.6Keywords: test
Target Milestone: 4.3 RC1   
Hardware: PC   
OS: Linux-GTK   
Whiteboard:
Bug Depends on:    
Bug Blocks: 51538    

Description Martin Oberhuber CLA 2009-12-03 09:13:40 EST
Build ID: HEAD as of 3-Dec-2009 15:00 CET

Running the core.resources tests locally on RHEL 4 update 8 x86 32-bit with the default distribution's Sun 1.5.0_20 JVM, I see 2 test failures which I do not see on x86_64 or WinXP:

org.eclipse.core.tests.internal.localstore.HistoryStoreTest
  testAddStateAndPolicies
  testClean

This may be a transient failure but I'd like to see it tracked.

junit.framework.AssertionFailedError: 3.5 expected:<0> but was:<5>
	at org.eclipse.core.tests.internal.localstore.HistoryStoreTest.testAddStateAndPolicies(HistoryStoreTest.java:349)



junit.framework.AssertionFailedError: 5.1 expected:<0> but was:<3>
	at org.eclipse.core.tests.internal.localstore.HistoryStoreTest.testClean(HistoryStoreTest.java:598)
Comment 1 Dani Megert CLA 2011-04-15 05:00:24 EDT
Running against Java 7 on Linux I go this:

junit.framework.AssertionFailedError: 1.3.2
at org.eclipse.core.tests.internal.localstore.HistoryStoreTest.testAddStateAndPolicies(HistoryStoreTest.java:263)

Need to see whether it happens again.

NOTE: A common cause for failure on Java 7 is that the tests are executed in different order. Maybe that's the problem here as well.
Comment 2 Dani Megert CLA 2011-04-15 05:00:53 EDT
*** Bug 129950 has been marked as a duplicate of this bug. ***
Comment 3 Dani Megert CLA 2011-04-19 02:42:29 EDT
Passes again on Java 7.
Comment 4 Dani Megert CLA 2011-04-19 02:52:54 EDT
>(In reply to comment #3)
>> Passes again on Java 7.
I was too fast: there was a problem generating the results and the link pointed to Java 6 instead of Java 7. We have to wait for the next Java 7 test results.
Comment 5 Dani Megert CLA 2011-04-19 09:11:58 EDT
> >(In reply to comment #3)
> >> Passes again on Java 7.
> I was too fast: there was a problem generating the results and the link 
> pointed to Java 6 instead of Java 7. We have to wait for the next Java 7 test 
> results.
Now verified: passes on Java 7.
Comment 6 Dani Megert CLA 2013-05-13 10:14:42 EDT
This test seems to be unstable - failed again:

http://download.eclipse.org/eclipse/downloads/drops4/I20130510-2000/testresults/html/org.eclipse.core.tests.resources_linux.gtk.x86_6.0.html


The test should be fixed or disabled.
Comment 7 John Arthorne CLA 2013-05-13 10:43:25 EDT
There is a bad assumption in the test that multiple edits will always have a different timestamp. Depending on resolution of the disk times or speed of disk this may not be true. Trying this fix:

http://git.eclipse.org/c/platform/eclipse.platform.resources.git/commit/?id=f8363cf55248db9981e1e78fb113724b2b6aabcb
Comment 8 Dani Megert CLA 2013-05-14 07:48:48 EDT
Verified in I20130513-2000.