Getting an Error in ATF

KS86
Tera Contributor

Getting this error "This step failed because the client error 'GlideAjax.getXMLWait is no longer supported' was detected on the page being tested. See failing Test Logs. To ignore these errors in the next test run, use 'Add all client errors to warning/ignored list' links." 

 

What is the issue?  How to get rid of this? Currently test is not passing.  

 

Note - I am able submit Record Producer manually, no error is appearing.

 

KS86_0-1781095857234.png

 

4 REPLIES 4

Dr Atul G- LNG
Tera Patron

https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0725054

 

https://www.servicenow.com/community/developer-forum/automated-test-framework-atf-throws-errors-when...

*************************************************************************************************************
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/dratulgrover [ Connect for 1-1 Session]

****************************************************************************************************************

Tanushree Maiti
Tera Patron

Hi @KS86 

 

Refer:

How To: Async GlideAjax in an onSubmit script

 KB0623238 Automated Test Framework error: "This step failed because a client-side Javascript error w... 

 

Please Accept the solution if it assisted you with your question & Mark this response as Helpful.
Regards
Tanushree Maiti
ServiceNow Technical Architect
LinkedIn: https://www.linkedin.com/in/tanushreemaiti

Shaqeel
Mega Sage

Hi @KS86 

 

Open the failed step and click on "Add all error to ignored list"

In your test uncheck "Fail on server error"

Shaqeel_0-1781171147771.png

 


***********************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting "Accept as Solution" and " Helpful." This action benefits both the community and me.

***********************************************************************************************************************





Regards

Shaqeel

PoonkodiS
Giga Sage

@KS86 

Your code uses GlideAjax.getXMLWait(), which is a synchronous function that freezes the browser

Find the Client Script running on that Record Producer and change getXMLWait() to an asynchronous getXML() call with a callback function:

// Change this:
ga.getXMLWait();
var ans = ga.getAnswer();

// To this:
ga.getXML(callbackFunction);

function callbackFunction(response) {
var ans = response.responseXML.documentElement.getAttribute("answer");
}

Try this approach