Catching exceptions 24/08/2012
begin
  browser.link(:id => 'not existing').click
rescue Watir::Exception::UnknownObjectException
  # Do something useful
  p "Element not found"
end

Sometimes there are exceptions coming back from the webdriver due to several possible problematic situations. For example, an element is not found or it is not clickable. The tests should not break in such a situation but the exceptions should be handled gracefully.