Unable to verify IF element present or not

The verifyElementPresent() method acts as an assertion, which means that if the method returns false, the test will stop, and the if statement won’t even be evaluated. The solution is to add a FailureHandling argument to the verifyElementPresent() method call. See the solution to a similar topic here: