'Returns true if alert was confirmed, false if it was dismissed
This keyword will fail if no alert is present. Note that
following keywords will fail unless the alert is
dismissed by this keyword or another like `Get Alert Message`.'

@keyword
def dismiss_alert(self, accept=True):

    if accept:
        return self._handle_alert(self.ACCEPT_ALERT)
    else:
        return self._handle_alert()
