Interested in a ServiceNow event built for developers? Registration for now[dev]26 is officially open!

ATF – How to set dynamically populated Select Box variable in Service Portal?

kwija
Mega Contributor

Hi,

I’m working on an ATF test for a Service Catalog item in Service Portal and have an issue with the Set Variable Values (SP) test step.

The catalog item contains a Select Box variable called request_type_choices. The choices for this variable are not configured statically on the variable itself. They are populated dynamically by an existing Catalog Client Script.

When I configure the standard Set Variable Values (SP) ATF step, I cannot select any of these dynamically generated values.

The value is available on the actual Service Portal form, but it is not available when configuring the ATF step.

I cannot modify the existing Catalog Client Script, so I’m looking for an ATF-side solution.

kwija_0-1788853108499.png

 

 

5 REPLIES 5

@Ankur Bawiskar 
No, this variable is part of variable set used in couple different cat. items (different selections based to cat. item) and for that onLoad Catalog Client Script is used. So when user opens this cat. item in Service Portal can see available choices; but when try to user Set Variable Values (SP) ATF step there are no choices (as in above screenshot). I tried to create new Test Step Config but it is not possible to create new UI steps. Here is Catalog Client Script:

kwija_0-1788872676007.png