assertNull("Ephemeral property seems to have been saved",
config.getSimpleValue(TestAlertSender.EPHEMERAL_PROPERTY_NAME, null));
}
private List<AlertDefinition> testDependentAlertDefinitions(int expectedParentId, ParentType parentType) {
AlertDefinitionCriteria crit = new AlertDefinitionCriteria();
Set<Integer> resourceIds = new HashSet<Integer>(resources.size());
for (Resource r : resources) {
resourceIds.add(r.getId());
}
if (parentType == ParentType.TEMPLATE) {
crit.addFilterAlertTemplateParentId(expectedParentId);
} else if (parentType == ParentType.GROUP) {
crit.addFilterGroupAlertDefinitionId(expectedParentId);
}
crit.fetchAlertNotifications(true);
List<AlertDefinition> checkList = LookupUtil.getAlertDefinitionManager().findAlertDefinitionsByCriteria(
subject, crit);
assertNotNull("Failed to retrieve the save alert definition", checkList);