[rspec-users] should_receive, used in the wrong place?
lancecarlson at gmail.com
Fri Aug 17 17:34:09 EDT 2007
what about template.should_receive(:current_user)?
I don't know if that's a bad idea to do that in the before(:each) but
it's more convenient..
On 8/17/07, Courtenay <court3nay at gmail.com> wrote:
> What do you guys think of this: if someone calls should_receive
> outside of an "it" block, it warns you.
> before(:each) do
> @foo = Foo.new
> would warn you that you're setting an expectation in the wrong place,
> and that "stub" is correct when setting up objects.
> rspec-users mailing list
> rspec-users at rubyforge.org
More information about the rspec-users