I have an array
String testArray = [‘Activities 1’, ‘19’, ‘15’,“','Object Repository/Page_Editing the Activity/a_Friday”, ‘Activities 2’, ‘10’, ‘0’,‘Object Repository/Page_Editing the Activity/a_Sunday’]
I want to use this to select options in a drop down box (it has the days of the week)
I tried:
TestObject to = findTestObject(‘Object Repository/Page_Editing the Activity/a_Friday’)
but this can’t find and click the object when I do this
WebUI.click(to)
what I’d hoped to do was create a series of variable mo, tues, wed etc and put them in the array:
String testArray = [‘Activities 1’, ‘19’, ‘15’,mon, ‘Activities 2’, ‘10’, ‘0’,wed]
then do
WebUI.click)testArray(3) etc
Can’t get it to work at all. It throws
[FAILED] - Test Cases/Activities/Create activities data set up FAILED because (of) (Stack trace: com.kms.katalon.core.exception.StepFailedException: Unable to click on object ‘Object Repository/Page_Editing the Activity/a_Friday’ (Root cause: com.kms.katalon.core.webui.exception.WebElementNotFoundException: Web element with id: ‘Object Repository/Page_Editing the Activity/a_Friday’ located by ‘By.xpath: //a[(text() = ‘Friday’ or . = ‘Friday’)]’ not found)
at com.kms.katalon.core.keyword.internal.KeywordMain.stepFailed(KeywordMain.groovy:32)
Help