Quantcast
Channel: New board topics in SmartBear Community
Viewing all articles
Browse latest Browse all 21061

can't get property expansion to work...

$
0
0

I am trying to access testcase variables in a loop, but I can't get the property expansion to work.

I have testcase variables with values (holiday_1, holiday_2, etc.)

Here's what I have (bare bones):

 

for (i=1; i<=16; i++)
{
 def curHolidayVariable = "holiday_"+i
 def holidayVariable = context.expand("\${#TestCase#curHolidayVariable}")
 log.info ("holidayVariable : ${holidayVariable}")

}

 

holidayVariable is always empty. Any help would be appreciated...


Viewing all articles
Browse latest Browse all 21061

Trending Articles