return taskTO;
}
private String createNotificationTask() {
// 1. Create notification
NotificationTO notification = new NotificationTO();
notification.setTraceLevel(TraceLevel.FAILURES);
notification.addEvent("[REST]:[UserController]:[]:[create]:[SUCCESS]");
notification.addEvent("[REST]:[UserController]:[]:[createInternal]:[SUCCESS]");
MembershipCond membCond = new MembershipCond();
membCond.setRoleId(7L);
notification.setAbout(NodeCond.getLeafCond(membCond));
membCond = new MembershipCond();
membCond.setRoleId(8L);
notification.setRecipients(NodeCond.getLeafCond(membCond));
notification.setSelfAsRecipient(true);
notification.setRecipientAttrName("email");
notification.setRecipientAttrType(IntMappingType.UserSchema);
String sender = "syncope86@syncope.apache.org";
notification.setSender(sender);
String subject = "Test notification SYNCOPE-86";
notification.setSubject(subject);
notification.setTemplate("optin");
Response response = notificationService.create(notification);
notification = getObject(response, NotificationTO.class, notificationService);
assertNotNull(notification);