class RSpec::Core::MultipleExceptionError

and one in an ‘after` block.
individual spec has multiple exceptions, such as one in the `it` block
multiple sub-exceptions. This is used in situations where a single
Provides a single exception instance that provides access to

def exception_count_description

return [String] A description of the failure/error counts.
def exception_count_description
  failure_count = Formatters::Helpers.pluralize(failures.size, "failure")
  return failure_count if other_errors.empty?
  error_count = Formatters::Helpers.pluralize(other_errors.size, "other error")
  "#{failure_count} and #{error_count}"
end

def initialize(*exceptions)

Parameters:
  • exceptions (Array) -- The initial list of exceptions.
def initialize(*exceptions)
  super()
  @failures                = []
  @other_errors            = []
  @all_exceptions          = []
  @aggregation_metadata    = { :hide_backtrace => true }
  @aggregation_block_label = nil
  exceptions.each { |e| add e }
end

def message

Other tags:
    Note: - RSpec does not actually use this -- instead it formats each exception

Returns:
  • (String) - Combines all the exception messages into a single string.
def message
  all_exceptions.map(&:message).join("\n\n")
end

def summary

Returns:
  • (String) - A summary of the failure, including the block label and a count of failures.
def summary
  "Got #{exception_count_description}"
end