### Question:
AuditTasks { public void isDeleteAuditNeeded(BuildingBlockExecution execution) { try { logger.debug("deleteAuditInventoryNeeded Value: {}", env.getProperty("mso.infra.deleteAuditInventory")); execution.setVariable("auditInventoryNeeded", Boolean.parseBoolean(env.getProperty("mso.infra.deleteAuditInventory"))); } catch (Exception ex) { exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex); } }  void isAuditNeeded(BuildingBlockExecution execution); void isDeleteAuditNeeded(BuildingBlockExecution execution); void setupAuditVariable(BuildingBlockExecution execution);  }### Answer:
@Test public void deleteAuditIsNeededTest() { when(env.getProperty("mso.infra.deleteAuditInventory")).thenReturn("true"); auditTasks.isDeleteAuditNeeded(execution); assertNotNull(execution.getVariable("auditInventoryNeeded")); assertEquals(execution.getVariable("auditInventoryNeeded"), true); }
@Test public void deleteAuditIsNotNeededTest() { when(env.getProperty("mso.infra.deleteAuditInventory")).thenReturn("false"); auditTasks.isDeleteAuditNeeded(execution); assertNotNull(execution.getVariable("auditInventoryNeeded")); assertEquals(execution.getVariable("auditInventoryNeeded"), false); }