Hi Katalon Community,
can we customize the default failure screenshot location : C:\Users\AppData\Local\Temp\Katalon\Test Cases.
Thank you!
Hi Katalon Community,
can we customize the default failure screenshot location : C:\Users\AppData\Local\Temp\Katalon\Test Cases.
Thank you!
hi,please help me.
Can catalone only take 5 screenshots? I want catalone to be able to take more pictures. before login and after login (database excel 5 field)
scrippt
WebUI.openBrowser(’’)
WebUI.navigateToUrl(‘http://demoaut.katalon.com/’)
Exceldata = findTestData(‘databasedemo’)
//for (def index : (1…Exceldata.getRowNumbers())) {
WebUI.click(findTestObject(‘Object Repository/Page_CURA Healthcare Service/a_Make Appointment’))
WebUI.setText(findTestObject(‘Object Repository/Page_CURA Healthcare Service/input_Username_username’), username)
//WebUI.setText(findTestObject(‘Object Repository/Page_CURA Healthcare Service/input_Username_username’), Exceldata.getValue(‘username’, index))
WebUI.setText(findTestObject(‘Object Repository/Page_CURA Healthcare Service/input_Password_password’), password)
//WebUI.setText(findTestObject(‘Object Repository/Page_CURA Healthcare Service/input_Password_password’), Exceldata.getValue(‘password’, index))
Date today = new Date()
String todaysDate = today.format(‘MM_dd_yy’)
String nowTime = today.format(‘hh_mm_ss’)
WebUI.takeScreenshot((((‘C:\Users\user\Katalon Studio\screenshot\login_’ + todaysDate) + ‘-’) + nowTime) + ‘.PNG’)
WebUI.click(findTestObject(‘Object Repository/Page_CURA Healthcare Service/button_Login’))
WebUI.takeScreenshot((((‘C:\Users\user\Katalon Studio\screenshot\login_’ + todaysDate) + ‘-’) + nowTime) + ‘.PNG’)
if (WebUI.verifyTextPresent(‘Login failed! Please ensure the username and password are valid’, false, FailureHandling.CONTINUE_ON_FAILURE)) {
println(’--------- failed login test-------------------’)
} else {
WebUI.delay(3)
WebUI.click(findTestObject('Object Repository/Page_CURA Healthcare Service/a_CURA Healthcare_menu-toggle'))
WebUI.click(findTestObject('Object Repository/Page_CURA Healthcare Service/a_Logout'))
println('--------- log out successfull tes-------------------')
}
WebUI.closeBrowser()