Bug 412486 - 40 failures in Rename* tests
Summary: 40 failures in Rename* tests
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Debug (show other bugs)
Version: 4.3   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 4.3.1   Edit
Assignee: Michael Rennie CLA
QA Contact:
URL:
Whiteboard:
Keywords: test
Depends on:
Blocks:
 
Reported: 2013-07-08 05:38 EDT by Dani Megert CLA
Modified: 2013-07-23 02:42 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Comment 1 Michael Rennie CLA 2013-07-08 12:21:34 EDT
Pushed a fix to master:

http://git.eclipse.org/c/jdt/eclipse.jdt.debug.git/commit/?id=104dcc4aaf75b837bffad74d4e782e32b821f6e8

Pushed fix to 4_3_maintenance:

http://git.eclipse.org/c/jdt/eclipse.jdt.debug.git/commit/?h=R4_3_maintenance&id=6d7649ec79e1559061e11f6bdd7f3ee8afa77c7b

The fix will throw our TestAgainException to retry the test if there is a resource exception during the refactoring - which will work even in a partially modified state because the tests reset the workspace before each run.
Comment 3 Michael Rennie CLA 2013-07-10 10:00:04 EDT
(In reply to comment #2)
> This did not do the trick, see
> http://download.eclipse.org/eclipse/downloads/drops4/I20130709-0800/
> testresults/html/org.eclipse.jdt.debug.tests_win32.win32.x86_7.0.html

Dang, oh well, I guess I will try also trapping CoreExceptions as well:

Caused by: org.eclipse.core.runtime.CoreException: The file is not synchronized with the local file system.

Also found that the debug test workspace has ResourcesPlugin.PREF_AUTO_REFRESH and  ResourcesPlugin.PREF_LIGHTWEIGHT_AUTO_REFRESH set to false.

Added a check to master for CoreException and turned on the external refresh preferences: http://git.eclipse.org/c/jdt/eclipse.jdt.debug.git/commit/?id=c941e797e533bd2628028ff957c55ddbfe059abe

Since these test have never failed locally, I tested doing the following:

1. put a breakpoint in AbstractRefactoringDebugTest#performRefactor line 68
2. debug one of the failing tests (for example RenameInnerTypeUnitTests)
3. when the breakpoint suspends open the file being refactored externally and make an edit
4. resume the test

I'll leave this open until we get the tests run in the next build. 

Also pushed changes to Gerrit for 4.3.1 changes: https://git.eclipse.org/r/#/c/14447/
Comment 4 Dani Megert CLA 2013-07-11 05:22:00 EDT
(In reply to comment #3)
> Also pushed changes to Gerrit for 4.3.1 changes:
> https://git.eclipse.org/r/#/c/14447/

This change has been merged into the repo.
Comment 5 Michael Rennie CLA 2013-07-22 11:41:10 EDT
(In reply to comment #4)
> (In reply to comment #3)
> > Also pushed changes to Gerrit for 4.3.1 changes:
> > https://git.eclipse.org/r/#/c/14447/
> 
> This change has been merged into the repo.

The test have not failed since the last update. Marking this as fixed.