tests for auto variables fixes (locals from outer classes)
authorEgor.Ushakov <egor.ushakov@jetbrains.com>
Tue, 14 Jul 2015 16:19:24 +0000 (19:19 +0300)
committerEgor.Ushakov <egor.ushakov@jetbrains.com>
Tue, 14 Jul 2015 16:21:55 +0000 (19:21 +0300)
java/testFramework/src/com/intellij/debugger/ExecutionWithDebuggerToolsTestCase.java

index 5c4ba6b9baedb717159ac2d3081d94f62f96cc8e..19094ce1d354e4a9e84d090df66a15c78fdc325f 100644 (file)
@@ -87,7 +87,7 @@ public abstract class ExecutionWithDebuggerToolsTestCase extends ExecutionTestCa
 
   protected void resume(SuspendContextImpl context) {
     DebugProcessImpl debugProcess = context.getDebugProcess();
-    debugProcess.getManagerThread().schedule(debugProcess.createResumeCommand(context, PrioritizedTask.Priority.LOW));
+    debugProcess.getManagerThread().schedule(debugProcess.createResumeCommand(context, PrioritizedTask.Priority.LOWEST));
   }
 
   protected void stepInto(SuspendContextImpl context) {
@@ -114,11 +114,16 @@ public abstract class ExecutionWithDebuggerToolsTestCase extends ExecutionTestCa
   }
 
   protected void onBreakpoint(SuspendContextRunnable runnable) {
+    addDefaultBreakpointListener();
+    myScriptRunnables.add(runnable);
+  }
+
+  protected void addDefaultBreakpointListener() {
     if (myPauseScriptListener == null) {
       final DebugProcessImpl debugProcess = getDebugProcess();
-      
+
       assertTrue("Debug process was not started", debugProcess != null);
-      
+
       myPauseScriptListener = new DelayedEventsProcessListener(
         new DebugProcessAdapterImpl() {
           @Override
@@ -164,7 +169,6 @@ public abstract class ExecutionWithDebuggerToolsTestCase extends ExecutionTestCa
       );
       debugProcess.addDebugProcessListener(myPauseScriptListener);
     }
-    myScriptRunnables.add(runnable);
   }
 
   protected void printFrameProxy(StackFrameProxyImpl frameProxy) throws EvaluateException {