From a975969d42f77f775ca599f75c6e626634eb8517 Mon Sep 17 00:00:00 2001 From: Anna Kozlova Date: Wed, 25 Feb 2015 20:21:59 +0100 Subject: [PATCH] EA-64336 - assert: TestPackage$MySearchForTestsTask.run --- .../junit/src/com/intellij/execution/junit/TestPackage.java | 4 ++++ .../testng/configuration/SearchingForTestsTask.java | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/plugins/junit/src/com/intellij/execution/junit/TestPackage.java b/plugins/junit/src/com/intellij/execution/junit/TestPackage.java index 6bde0b4419dd..3cbf41a08ca1 100644 --- a/plugins/junit/src/com/intellij/execution/junit/TestPackage.java +++ b/plugins/junit/src/com/intellij/execution/junit/TestPackage.java @@ -33,6 +33,7 @@ import com.intellij.openapi.application.ApplicationManager; import com.intellij.openapi.module.Module; import com.intellij.openapi.module.ModuleManager; import com.intellij.openapi.module.ModuleUtilCore; +import com.intellij.openapi.progress.ProcessCanceledException; import com.intellij.openapi.progress.ProgressIndicator; import com.intellij.openapi.progress.ProgressManager; import com.intellij.openapi.progress.Task; @@ -396,6 +397,9 @@ public class TestPackage extends TestObject { }); myFoundTests = !myClasses.isEmpty(); } + catch (ProcessCanceledException e) { + throw e; + } catch (IOException e) { LOG.info(e); } diff --git a/plugins/testng/src/com/theoryinpractice/testng/configuration/SearchingForTestsTask.java b/plugins/testng/src/com/theoryinpractice/testng/configuration/SearchingForTestsTask.java index df82e1dd80fa..3e532757c54a 100644 --- a/plugins/testng/src/com/theoryinpractice/testng/configuration/SearchingForTestsTask.java +++ b/plugins/testng/src/com/theoryinpractice/testng/configuration/SearchingForTestsTask.java @@ -27,6 +27,7 @@ import com.intellij.openapi.application.ApplicationManager; import com.intellij.openapi.application.PathManager; import com.intellij.openapi.diagnostic.Logger; import com.intellij.openapi.module.Module; +import com.intellij.openapi.progress.ProcessCanceledException; import com.intellij.openapi.progress.ProgressIndicator; import com.intellij.openapi.progress.Task; import com.intellij.openapi.project.DumbService; @@ -109,6 +110,9 @@ public class SearchingForTestsTask extends Task.Backgroundable { logCantRunException(e); } } + catch (ProcessCanceledException e) { + throw e; + } catch (IOException e) { LOG.info(e); }