Forum Discussion

MHealton's avatar
New Contributor
3 years ago

Execution Plan: running script that accepts python list as a parameter?

I'm working on testing a page that has a select multiple element (see HTML select multiple Attribute (, and I wrote up a little Python script to accept any number of locations in a python list, then ctrl+click to select every item in the list. I separated the first click to deal with a persistence issue we had between tests.




def TestScript(business_name: string, locations:list):
  for index, location in enumerate(locations):
    if not index:
      (selector).ClickItem(location, skCtrl)




I can call this function in another script, and successfully pass in all the string values I want, but what I'm wondering is this: is it possible to run this script in an execution plan, or as part of a keyword test? I can't see a way to supply a list parameter, so I'm kinda stumped... If it's not possible, is there a workaround to speak of?


2 Replies