On Mon, Mar 24, 2008 at 11:54 AM, aslak hellesoy <[EMAIL PROTECTED]> wrote: > On Mon, Mar 24, 2008 at 4:38 PM, Rick DeNatale <[EMAIL PROTECTED]> wrote: > > I've got this example 'group': > > > > before(:all) do > > @mock_user = mock_model(User) > > @mock_email_field = mock_model(EmailField, :user => @mock_user) > > @mock_email_field.stub!(:user).and_return(@mock_user) > > EmailField.stub!(:find_by_value).and_return(@mock_email_field) > > end > > > > before(:all) will only be executed once - before all of your examples. > Why are you using before(:all)?
Because I had a brain f*rt. Actually I just caught this myself before checking back with the list. Thanks! -- Rick DeNatale My blog on Ruby http://talklikeaduck.denhaven2.com/ _______________________________________________ rspec-users mailing list [email protected] http://rubyforge.org/mailman/listinfo/rspec-users
