def detach(lun_or_snap): if lun_or_snap.name == 'detach_failure': raise ex.DetachIsCalled()
def detach(host, lun_or_snap): error_ids = ['lun_43', 'snap_0'] if host.name == 'host1' and lun_or_snap.get_id() in error_ids: raise ex.DetachIsCalled()
def detach(lun_or_snap): if lun_or_snap.name == 'detach_failure': raise ex.DetachIsCalled()
def detach(host, lun_or_snap): error_ids = ['lun_43', 'snap_0'] if host.name == 'host1' and lun_or_snap.get_id() in error_ids: raise ex.DetachIsCalled()