ATF: "Request More Information" UI Action Sends Email in UI but Not During ATF Execution

Sachin G K1
Kilo Sage

Hi All,

 

I’m currently working on an Automated Test Framework (ATF) test for a Policy Exception record. When a user clicks the "Request More Information" UI action manually, an email notification is correctly triggered and sent to the requester.

 

However, when the same action is performed as part of an ATF test, no email record is created in the sys_email table, which subsequently causes the next test step—validating the outbound email—to fail.

 

SachinGK1_0-1745914865555.png

Requesting for help here.

 

Thanks in Advance,

Sachin

16 REPLIES 16

yes ankur

 

@Sachin G K1 

did you give some timeout for that step sufficient enough?

 

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

@Ankur Bawiskar 

As you can see in below screenshot, i have given 40sec timeout to record query step, however now i added another step above it to provide sleep of 30sec.but still getting same error

SachinGK1_0-1745934118222.png

 

@Sachin G K1 

the link I shared has solution which worked, but you will have to debug it further

what's written in Run Server side script step?

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Hi @Ankur Bawiskar ,

 

I removed query record and server script, and added validate outbound email step, with condition as below and it worked:

SachinGK1_0-1745936255332.png

Later i added another condition as below and it failed:

SachinGK1_1-1745936319159.png

Note: Subject is correct

Note: there are 2 notifications that will be sent first one is when PE is assigned and second one is when ui action is clicked which has subject starts with "More information is needed for policy exception"

 

My assumptions: Validate Outbound email is returning success for the first notification and i think second notification is not getting triggered thereby its getting failed when i inserted second condition