lambdium icon indicating copy to clipboard operation
lambdium copied to clipboard

Graceful exit

Open Dasio opened this issue 5 years ago • 0 comments

Is there any way how to graceful exit script when selenium throw some error? e.g $browser.findElement($driver.By.css("input[type='email']")) when there is no such element I would like to propagate this error outside with console log of chrome(not necessary). But the only way is to throw error from script, but that's not possible from catch in promise $browser.findElement($driver.By.css("input[type='email']")).catch(function(err) { throw 42;})); This can't work.

I would like to know where the error occured and log it.

Dasio avatar Oct 16 '18 08:10 Dasio