@Test
public void isValidResultIfZeroErrorCode() throws MavenInvocationException {

    InvocationResult r = Mockito.mock(InvocationResult.class);
    Map<Class<? extends MavenInvocationOutputHandler>, Object> value = new HashMap<Class<? extends MavenInvocationOutputHandler>, Object>();
    value.put(new GenericErrorsOutputHandler().getClass(), "Hello!");
    Mockito.when(multipleOutputHandler.getResult()).thenReturn(value);
    Mockito.when(r.getExitCode()).thenReturn(0);
    Mockito.when(r.getExecutionException()).thenReturn(null);
    Mockito.when(invoker.execute(request)).thenReturn(r);
    TUExecutionResult result = mavenGoal.execution(new File("/blah/pom.xml"), null);
    assertEquals(result.getException(), null);
    assertEquals(result.getValue(), value);
}