use of org.eclipse.che.api.debug.shared.dto.action.StepIntoActionDto in project che by eclipse.
the class AbstractDebugger method stepInto.
@Override
public void stepInto() {
if (isConnected()) {
for (DebuggerObserver observer : observers) {
observer.onPreStepInto();
}
removeCurrentLocation();
preserveDebuggerState();
StepIntoActionDto action = dtoFactory.createDto(StepIntoActionDto.class);
action.setType(Action.TYPE.STEP_INTO);
Promise<Void> promise = service.stepInto(debugSessionDto.getId(), action);
promise.catchError(new Operation<PromiseError>() {
@Override
public void apply(PromiseError arg) throws OperationException {
Log.error(AbstractDebugger.class, arg.getCause());
}
});
}
}
use of org.eclipse.che.api.debug.shared.dto.action.StepIntoActionDto in project che by eclipse.
the class DebuggerTest method testStepInto.
@Test
public void testStepInto() throws Exception {
StepIntoActionDto stepIntoAction = mock(StepIntoActionDto.class);
doReturn(promiseVoid).when(service).stepInto(SESSION_ID, stepIntoAction);
doReturn(stepIntoAction).when(dtoFactory).createDto(StepIntoActionDto.class);
debugger.stepInto();
verify(observer).onPreStepInto();
assertTrue(debugger.isConnected());
verify(promiseVoid).catchError(operationPromiseErrorCaptor.capture());
operationPromiseErrorCaptor.getValue().apply(promiseError);
verify(promiseError).getCause();
}
Aggregations