@Test
public void testDispose() throws Exception
{

    doReturn( Sets.newHashSet( checkWorkflow ) ).when( activeWorkflows ).values();
    environmentManager.dispose();
    verify( cachedExecutor ).shutdown();
    verify( scheduledExecutor ).shutdown();
    verify( checkWorkflow ).cancel();
}