mirror of
https://github.com/pry/pry.git
synced 2022-11-09 12:35:05 -05:00
Remove version guard from LastException check
In the happy path, the object is a RuntimeError and therefore inherits from Object. In the sad path, failing when we try to bind the method is just as informative as failing the actual assertion.
This commit is contained in:
parent
67806cff46
commit
8b4000c969
1 changed files with 2 additions and 7 deletions
|
@ -29,13 +29,8 @@ describe "Sticky locals (_file_ and friends)" do
|
|||
input '_ex_.message == "halp"'
|
||||
output '=> true'
|
||||
|
||||
if Pry::Helpers::BaseHelpers.mri_20? || Pry::Helpers::BaseHelpers.mri_21?
|
||||
input 'Kernel.instance_method(:class).bind(_ex_).call'
|
||||
output '=> RuntimeError'
|
||||
end
|
||||
|
||||
input '_ex_.wrapped_exception'
|
||||
output /NoMethodError/
|
||||
input 'Kernel.instance_method(:class).bind(_ex_).call'
|
||||
output '=> RuntimeError'
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue