SteppingTest: select target for smart step by its name not by index to avoid cryptic...
authornik <Nikolay.Chashnikov@jetbrains.com>
Wed, 5 Aug 2015 12:54:44 +0000 (15:54 +0300)
committernik <Nikolay.Chashnikov@jetbrains.com>
Wed, 5 Aug 2015 12:55:12 +0000 (15:55 +0300)
java/testFramework/src/com/intellij/debugger/DebuggerTestCase.java
java/testFramework/src/com/intellij/debugger/ExecutionWithDebuggerToolsTestCase.java

index b05fd4bfbb5139faeb34f61a5e6e1e5f59b7e3d5..3aa8106ee2820b7c83060ba18cdc9abf8fbcf3fc 100644 (file)
@@ -92,6 +92,7 @@ public abstract class DebuggerTestCase extends ExecutionWithDebuggerToolsTestCas
       assertNull(DebuggerManagerEx.getInstanceEx(myProject).getDebugProcess(getDebugProcess().getProcessHandler()));
       myDebuggerSession = null;
     }
+    throwExceptionsIfAny();
     checkTestOutput();
   }
 
index e5501e20b062bc9d8e7379552d1e197153d8dbf8..798233bf7606ff9ef1ccf1790d6b2350a5d78bb9 100644 (file)
@@ -108,8 +108,12 @@ public abstract class ExecutionWithDebuggerToolsTestCase extends ExecutionTestCa
   @Override
   protected void tearDown() throws Exception {
     super.tearDown();
+    throwExceptionsIfAny();
+  }
+
+  protected void throwExceptionsIfAny() throws CompositeException {
     synchronized (myException) {
-      if (!myException.isEmpty()) throw myException;
+      myException.throwIfNotEmpty();
     }
   }