Create ATF based on condition query
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hello
I'm looking at the step: Run server side script to query the (custom fax table) for an idea
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
You haven't given enough information on how all this is implemented so I am assuming a little bit. If your query is a client callable script include I would probably just create a private parameterized method in the SI that handles the server side logic which can be tested separately if needed.
Then the ui/glideajax part can be tested separately in a test that follows this logic:
- create and impersonate user (+ set the values/create the artifacts needed for your fax number logic)
- open catalog item
- validate variable states assuming your check has run and changed the states at this point
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hi @SnowDevOps ,
Here is the steps :
Step 1: Generate a new user specifically for this test run.
Step 2: Add a record to your custom table.
Link the User field in this table to the user created in Step 1 using a data pill.
Enter a sample value in the Fax Number field.
Step 3: Impersonate the newly created user from Step 1.
Step 4: Open your Fax Catalog Item.
Allow the form to load completely so that all client scripts finish retrieving data from the table.
Step 5: Confirm that the relevant fields are displayed or hidden according to the expected behavior.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
so what you started and where are you stuck?
You can use Run Server Side Script step and get the data and then compare
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 10x ServiceNow MVP || ✨ ServiceNow Community Leader
