1
0
Fork 0
mirror of https://github.com/pry/pry.git synced 2022-11-09 12:35:05 -05:00

exclude rbx properly

This commit is contained in:
Conrad Irwin 2012-09-23 22:02:43 -07:00
parent 32ab9406d2
commit d350493de2

View file

@ -120,13 +120,12 @@ describe Pry::Method do
m.name.should == "gag"
end
if defined? BasicObject
if defined?(BasicObject) && !Pry::Helpers::BaseHelpers.rbx? # rubinius issue 1921
it "should find the right method from a BasicObject" do
a = Class.new(BasicObject) { def gag; ::Kernel.binding; end; def self.line; __LINE__; end }
m = Pry::Method.from_binding(a.new.gag)
m.owner.should == a unless Pry::Helpers::BaseHelpers.rbx? # rubinius issue 1921
m.owner.should == a
m.source_file.should == __FILE__
m.source_line.should == a.line
end