Just a general opinion question on idioms/common usage. Is it better to mock Ruby's base classes, or to use real instances of those base classes?
@string = mock String @string.stub!(:to_s).and_return "hello" # or: @string = "hello" I was wondering which is generally favored, and if so, for what reasons? Or is it highly dependent on the type of spec which is being written? Regards, Scott _______________________________________________ rspec-users mailing list [email protected] http://rubyforge.org/mailman/listinfo/rspec-users
