Hi,
this is my code which is passed and all actions until the end of the test case are beeing performed.
List dateCells = new ArrayList()
dateCells.add(‘//td[@id='userRow27_5_7']/div[last()]’)
dateCells.add(‘//td[@id='userRow27_12_7']/div[last()]’)
dateCells.add(‘//td[@id='userRow27_19_7']/div[last()]’)
dateCells.add(‘//td[@id='userRow27_26_7']/div[last()]’)
dateCells.add(‘//td[@id='userRow27_2_8']/div[last()]’)
for (i = 0; i < dateCells.size; i++) {
String strPath = dateCells.get(i)
int cntEvents = driver.findElements(By.xpath(strPath)).size()
KeywordUtil.markFailed("MARKFAILED by KeywordUtil" );
if (cntEvents < 1) {
KeywordUtil.markFailed('=====> Failed: cntEvents < 1: 1 was expected !!!!!!!')
println('=====> Failed: cntEvents < 1: 1 was expected !!!!!!!')
} else {
println('(\'=====> SUCCESS: Recurrence available')
}
CustomKeywords.'esHelper.es.checkReadiness'('Object Repository/Add and delete recurrence/a_Nchste Woche keyboard_arrow_right')
WebUI.click(findTestObject('Object Repository/Add and delete recurrence/a_Nchste Woche keyboard_arrow_right'))
WebUI.delay(1)
}
… code continues and is executed until the end of test case
After the browser was close I get this exeption:
2019-08-02 11:32:23.584 DEBUG event with validation of the time frame - 92: closeBrowser()
2019-08-02 11:32:24.888 ERROR c.k.katalon.core.main.TestCaseExecutor - Test Cases/Add and delete recurrence event with validation of the time frame FAILED.
Reason:
com.kms.katalon.core.exception.StepFailedException: MARKFAILED by KeywordUtil
at com.kms.katalon.core.util.KeywordUtil.markFailed(KeywordUtil.java:19)
at com.kms.katalon.core.util.KeywordUtil$markFailed.call(Unknown Source)
at Add and delete recurrence event with validation of the time frame.run(Add and delete recurrence event with validation of the time frame:171)
at com.kms.katalon.core.main.ScriptEngine.run(ScriptEngine.java:194)
at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(ScriptEngine.java:119)
at com.kms.katalon.core.main.TestCaseExecutor.runScript(TestCaseExecutor.java:337)
at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:328)
at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:307)
at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(TestCaseExecutor.java:299)
at com.kms.katalon.core.main.TestCaseExecutor.execute(TestCaseExecutor.java:233)
at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:114)
at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:105)
at com.kms.katalon.core.main.TestCaseMain$runTestCase$0.call(Unknown Source)
at TempTestCase1564738302420.run(TempTestCase1564738302420.groovy:21)
2019-08-02 11:32:24.906 INFO c.k.katalon.core.main.TestCaseExecutor - END Test Cases/Add and delete recurrence event with validation of the time frame.
My project settings:
What can I do to avoid this strange exception?`
Regards,
Matthias