Sha256: c082541e9776d41a12db18df669eef7b9feaf10bce3e6a6effff9d9c3c2c9aaa
Contents?: true
Size: 540 Bytes
Versions: 76
Compression:
Stored size: 540 Bytes
Contents
module MethodsSpecs class Issue < Object def unique_method_name end end # Trigger stub generation Issue.new.unique_method_name end describe "Kernel#methods" do it "lists methods available on an object" do Object.new.methods.include?("puts").should == true end it "lists only singleton methods if false is passed" do o = Object.new def o.foo; 123; end o.methods(false).should == ["foo"] end it "ignores stub methods" do Object.methods.include?(:unique_method_name).should be_false end end
Version data entries
76 entries across 76 versions & 3 rubygems