mirror of https://github.com/rails/rails
Fix CI error with minitest 5.14
Follow up to 2bf1c17c20
, which still left
this one failure. Minitest 5.14 uses error instead of exception, so
exception had been changed to just be the same UnexpectedError instance
and losing us the actual error message.
This also switches to initializing a new UnexpectedError instance
because previously, for reasons I can't quite figure out, reusing the
same instance would still give us a DRbConnError.
This commit is contained in:
parent
8c71793b3b
commit
268a099b1b
|
@ -101,8 +101,14 @@ module ActiveSupport
|
|||
begin
|
||||
queue.record(reporter, result)
|
||||
rescue DRb::DRbConnError
|
||||
result.failures.each do |failure|
|
||||
failure.send(:initialize, DRb::DRbRemoteError.new(failure.exception))
|
||||
result.failures.map! do |failure|
|
||||
if failure.respond_to?(:error)
|
||||
# minitest >5.14.0
|
||||
error = DRb::DRbRemoteError.new(failure.error)
|
||||
else
|
||||
error = DRb::DRbRemoteError.new(failure.exception)
|
||||
end
|
||||
Minitest::UnexpectedError.new(error)
|
||||
end
|
||||
queue.record(reporter, result)
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue