Making a Test Case fail after Passes

Here is a good one…
I can create a user
Log back in as admin and delete the user

all good

but I want a peace of mind and So I tried to make it fail and can’t

type in the email
Get Text when search results come back
If the user email exists Fail TC
Else print Yes

@rthomfohrde I am not able to understand what you are trying to do with this test case.

Can you please post your whole script ?

WebUI.callTestCase(findTestCase(‘Automation/_Sign In GovSpend Automation’), [:], FailureHandling.STOP_ON_FAILURE)‘Left Menu_OR/menu_Admin’))


WebUI.setText(findTestObject(‘Admin_OR/Page_Admin Organization GovSpend/input_Email Filter’), ‘’)

not_run:‘Admin_OR/Page_Admin Organization GovSpend/link_Agency Tester’))

not_run:‘Admin_OR/Page_Organization Users GovSpend/tab_Details’))

not_run:‘Admin_OR/Page_Organization Details GovSpend/button_Delete Org’))


not_run:‘Admin_OR/Page_Organization Details GovSpend/button_Delete confirm’))

not_run: WebUI.setText(findTestObject(‘Admin_OR/Page_Admin Organization GovSpend/input_Email Filter’), ‘’)

result = WebUI.getText(findTestObject(‘Left Menu_OR/Page_Admin Organization GovSpend/text_User email’))

//result = WebUI.getText(findTestObject(‘Admin_OR/Page_Admin Organization GovSpend/text_Test Tester (test5mailinatorcom)’))

if (result.contains(‘’)) {
} else {