Sha256: 93abc7aead9bec8b4c07fb0be90c83668a37a5aa7d73228409ef630867555a1d

Contents?: true

Size: 571 Bytes

Versions: 5

Compression:

Stored size: 571 Bytes

Contents

require File.dirname(__FILE__) + '/../spec_helper'

describe Object do
  
  describe "#get_binding" do
    it "should return the objects binding" do
      lambda {}.get_binding.should be_instance_of(Binding)
    end
  end

  describe "#method_missing" do
    it "should preserve its original behavior for missing methods" do
      lambda { i_am_a_missing_method() }.should raise_error(NoMethodError)
    end

    it "should preserve its original behavior for missing variables" do
      lambda { i_am_a_missing_variable }.should raise_error(NameError)
    end
  end

end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
commander-4.0.4 spec/core_ext/object_spec.rb
commander-4.0.3 spec/core_ext/object_spec.rb
commander-4.0.2 spec/core_ext/object_spec.rb
commander-4.0.1 spec/core_ext/object_spec.rb
commander-4.0.0 spec/core_ext/object_spec.rb