1414package org .eclipse .ui .tests .dialogs ;
1515
1616import static java .util .Arrays .asList ;
17- import static org .junit .Assume .assumeFalse ;
1817
1918import java .io .ByteArrayInputStream ;
2019import java .io .InputStream ;
2322import java .util .HashSet ;
2423import java .util .List ;
2524import java .util .Map ;
25+ import java .util .Map .Entry ;
2626import java .util .Set ;
2727
2828import org .eclipse .core .resources .IFile ;
3131import org .eclipse .core .resources .ResourcesPlugin ;
3232import org .eclipse .core .runtime .CoreException ;
3333import org .eclipse .core .runtime .NullProgressMonitor ;
34- import org .eclipse .core .runtime .Platform ;
3534import org .eclipse .swt .widgets .Composite ;
3635import org .eclipse .swt .widgets .Shell ;
3736import org .eclipse .swt .widgets .Table ;
@@ -288,7 +287,6 @@ public void testMultiSelectionAndSomeInitialNonExistingSelectionWithInitialPatte
288287 */
289288 @ Test
290289 public void testMultiSelectionAndTwoInitialSelectionsWithInitialPattern () {
291- assumeFalse ("Test fails on Windows: Bug 559353" , Platform .OS_WIN32 .equals (Platform .getOS ()));
292290
293291 boolean hasMultiSelection = true ;
294292 List <IFile > initialSelection = asList (FILES .get ("foo.txt" ), FILES .get ("bar.txt" ));
@@ -312,7 +310,6 @@ public void testMultiSelectionAndTwoInitialSelectionsWithInitialPattern() {
312310 */
313311 @ Test
314312 public void testMultiSelectionAndTwoInitialFilteredSelections () {
315- assumeFalse ("Test fails on Windows: Bug 559353" , Platform .OS_WIN32 .equals (Platform .getOS ()));
316313
317314 boolean hasMultiSelection = true ;
318315
@@ -383,7 +380,18 @@ protected void doTearDown() throws Exception {
383380 dialog .close ();
384381 }
385382 if (project != null ) {
386- project .delete (true , null );
383+ try {
384+ project .delete (true , null );
385+ } catch (Exception e ) {
386+ // try to get a stacktrace which jobs still has project open so that it can not
387+ // be deleted:
388+ for (Entry <Thread , StackTraceElement []> entry : Thread .getAllStackTraces ().entrySet ()) {
389+ Exception exception = new Exception ("ThreadDump for thread \" " + entry .getKey ().getName () + "\" " );
390+ exception .setStackTrace (entry .getValue ());
391+ e .addSuppressed (exception );
392+ }
393+ throw e ;
394+ }
387395 }
388396 super .doTearDown ();
389397 }
0 commit comments