1 require File.dirname(__FILE__) + '/../../spec_helper.rb'
3 class LiarLiarPantsOnFire
8 def self.respond_to?(sym)
13 describe 'should_receive' do
15 @liar = LiarLiarPantsOnFire.new
18 it "should work when object lies about responding to a method" do
19 @liar.should_receive(:something)
23 it 'should work when class lies about responding to a method' do
24 LiarLiarPantsOnFire.should_receive(:something)
25 LiarLiarPantsOnFire.something
28 it 'should cleanup after itself' do
29 LiarLiarPantsOnFire.metaclass.instance_methods.should_not include("something")