Task task = new Task(jid, vid, 2, 7, eid, "TestTask", taskManager);
RuntimeEnvironment env = new RuntimeEnvironment(task, tdd, getClass().getClassLoader(),
mock(MemoryManager.class), mock(IOManager.class), mock(InputSplitProvider.class),
mock(AccumulatorProtocol.class), new BroadcastVariableManager());
task.setEnvironment(env);
assertEquals(ExecutionState.DEPLOYING, task.getExecutionState());