class RSpec::Matchers::BuiltIn::RaiseError

def expected_error

def expected_error
  case @expected_message
  when nil
    if RSpec::Support.is_a_matcher?(@expected_error)
      "Exception with #{description_of(@expected_error)}"
    else
      description_of(@expected_error)
    end
  when Regexp
    "#{@expected_error} with message matching #{description_of(@expected_message)}"
  else
    "#{@expected_error} with #{description_of(@expected_message)}"
  end
end