class RSpec::Expectations::FailureAggregator

def assign_backtrace(failure)

:nocov:
relative to the `aggregate_failures` block.
so that rspec-core's truncation logic can work properly on it to list the backtrace
a backtrace that has a continuous common section with the raised `MultipleExpectationsNotMetError`,
regards to `.java` stack frames. It's important that we use `raise` for JRuby to produce
On JRuby 9.1.x.x and before, `caller` and `raise` produce different backtraces with
def assign_backtrace(failure)
  raise failure
rescue failure.class => e
  failure.set_backtrace(e.backtrace)
end