fill sc_task variables via ATF

Jochen3
Kilo Explorer

Hi,

i want to fill field values in the sc_task with the ATF, f.e. in the Screen you can see the red variables. How i can fill them (without a script in the ATF) ? By using the OOTB "Set Field Values" i won't find the field "Servername", i also try dot-walking and don't find the "variable" Section. Maybe someone has a working "ATF Step Configuration" for "Set Field Values (Task)" ? Or any Solution ?

Thanks in front

Jochen

4 REPLIES 4

Ankush Agrawal
ServiceNow Employee
ServiceNow Employee

Hi Jochen

This support will be given in Orlando. We are adding support to test UI formattor/macros within a form via 'Custom UI' steps. I believe the UI shown are part of a Form (sc_request etc.). 

Orlando EA/RTP is starting from January. More details here: https://hi.service-now.com/kb_view.do?sysparm_article=KB0635446

--
Best Regards
Ankush

P.S. Please mark helpful/correct as appropriate to help the fellow community member in identifying the relevant answers.

Hi Ankush,

 

after "try and error": what actually works in the ATF Automated Test-Framework:

1. to fill a Variable (f.e. "assigned to" = a Task Variable) of the Workflow-Task (sc_Task) i use the Test Step "Set Field Values" in the Table sc_task

2. to fill a Variable of the RITM behind (Catalog Item Variable / Variable Set) i use Test Step "Set Variable Values" in the Catalog Item

 

But what i search: to fill Variables, that exists only in the Workflow (definied in the Workflow Properties) - i need to know These things for this

- which Test Step is necessary for this ?

- which table or Item ist to be adressed ?

- how can i adress the Variable in the Workflow (maybe dot-Walking, but where i can find them)

 

So, you have answers for this ?

Thanks in Front

Abdul30
Kilo Contributor

Hi Jochen, I believe you should be able to do this by using one of the following OOTB steps: 

  1. Products -> Variable State Validation: This step can be used to check the state of the variable such as (mandatory, visible, read-only, etc..)
  2. Products -> Validate Variable Values: This step can be used to validate the actual value that was selected within that variable.
  3. Products -> Set Variable Values: This step will populate a variable with a value. 

You have to make sure the task/form is first opened, then you can validate the variables. I hope this helps.

Thanks

---

Please mark my answer as correct if it has helped you. Thanks!

Tshar2311
Giga Contributor

Did you get any approach to handle this

I am struggling the same