@Test
public void tryLocalExecution() {

	try {
		jobManagerSystem.actorOf(Props.create(SuccessReturningActor.class), JobManager.JOB_MANAGER_NAME());
		
		PackagedProgram packagedProgramMock = mock(PackagedProgram.class);
		when(packagedProgramMock.isUsingInteractiveMode()).thenReturn(true);
		doAnswer(new Answer<Void>() {
			@Override
			public Void answer(InvocationOnMock invocation) throws Throwable {
				ExecutionEnvironment.createLocalEnvironment();
				return null;
			}
		}).when(packagedProgramMock).invokeInteractiveModeForExecution();
		try {
			new Client(config).runBlocking(packagedProgramMock, 1);
			fail("Creating the local execution environment should not be possible");
		}
		catch (InvalidProgramException e) {
			// that is what we want
		}
	}
	catch (Exception e) {
		e.printStackTrace();
		fail(e.getMessage());
	}
}