Sha256: 9f4fa9495460a4d58bfabce5d15a34224c4efd9bbee2b54f894f4678832f12ee

Contents?: true

Size: 599 Bytes

Versions: 10

Compression:

Stored size: 599 Bytes

Contents

require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')
require 'method_info/object_method'

module MethodInfo
  module ObjectMethod
    describe "method_info" do
      it "passes the object it was called on to the option handler" do
        @obj = Object.new
        OptionHandler.should_receive(:handle).with(@obj, anything)
        @obj.method_info
      end

      it "passes its options to the option handler" do
        OptionHandler.should_receive(:handle).with(anything, { :a => :one, :b => :two })
        Object.method_info(:a => :one, :b => :two)
      end
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
method_info-0.1.10 spec/method_info/object_method_spec.rb
method_info-0.1.9 spec/method_info/object_method_spec.rb
method_info-0.1.8 spec/method_info/object_method_spec.rb
method_info-0.1.7 spec/method_info/object_method_spec.rb
method_info-0.1.6 spec/method_info/object_method_spec.rb
method_info-0.1.5 spec/method_info/object_method_spec.rb
method_info-0.1.4 spec/method_info/object_method_spec.rb
method_info-0.1.3 spec/method_info/object_method_spec.rb
method_info-0.1.2 spec/method_info/object_method_spec.rb
method_info-0.1.0 spec/method_info/object_method_spec.rb