class Cucumber::Undefined

def self.from(result, step_name)

def self.from(result, step_name)
  return result.with_message(with_prefix(result.message)) if result.is_a?(self)
  begin
    raise self, with_prefix(step_name)
  rescue StandardError => e
    e
  end
end