How to Test Email Template Body with Dynamic values

Which IIQ version are you inquiring about?

8.1p3

Share all details about your problem, including any error messages you may have received.

Hello Forum,
I am working on email templates for certifications and my body consists of basic dynamic values like $ownerName , $expiration etc basic values.

I am able to generate emails via rule using below

EmailOptions options = new EmailOptions(toAddress, null);
  template.setBody("Test Email");
                   
  template.setSubject("Certification Email Template test") ;
  //options.setSendImmediate(true);
  context.sendEmailNotification(template, options);

But i am not able to test the dynamic values in the body. The Certificate only triggers alters after 1 days. There is no option to sends alerts immediately to test the template.

#if($expiration)
#if($expiration.getTime() > $nowDate.getTime())
is due on $spTools.formatDate($expiration,3,1).
#{else}
was due on $spTools.formatDate($expiration,3,1).
#{end}
#{else}
was due on $spTools.formatDate($oldDueDate,3,1).
#{end}

Please guide me on thtesting the template with dynamic values and dates, thanks

Hi @shivakarasani199,

Time machine feature allow to test the certification reminder and escalation without waiting days for them to execute.

Refer the link

https://community.sailpoint.com/t5/Technical-White-Papers/Testing-Certification-Reminders-and-Escalations/ta-p/77786

2 Likes

Thank you @Arun-Kumar
The solution worked , the task is triggering for all the work items and this is creating a lot of emails.
Is there a way we can just test the email body for once certification, just like how we run the rule to test the output.

Thanks

1 Like

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.