Anybody knows how can I capture an error (with try catch) and then continues the execution but cleaning the errors.
1. try to click on one button
2. (button doesn't exist) error captured in catch
3. log the error and clean it (becouse this button can exist or not, remember that it's an example)
4. when finnish the execution sais that all are OK
I say that it's just an example.
The real problem is that I don't know why if I click an existing button without try, Selenium clic in the button but say that it's an error an finnish the application. If I try to click with try-catch the button it's clicked and the automation continues, but when finnish says that have an error.
I would like to click, continue and then say that's all are ok.