[rspec-users] Does one use mocks in stories?

2008-03-23 Thread Alan Larkin
My site is an external Facebook app. I need users to come to the start page and if they are not already logged into their Facebook account (and have the app installed) see a button to take them to the Facebook login/install page. Using RFacebook, login is normally achieved with a before_filter. Th

Re: [rspec-users] "Why not MockEverthing" or why use fixtures for all tests?

2008-03-18 Thread Alan Larkin
David Schmidt wrote: > Hello fellow RSpec users. > > Before you all start warming up your flame throwers please let me > explain my Subject line. > > I've been working over 4 months on a large Rails project with a few > other developers. Test coverage was spotty at best, though they *were* >

Re: [rspec-users] Multiple should_receive(:render).with

2008-03-14 Thread Alan Larkin
Corey Haines wrote: > Stub out the first one, something like > > template.stub!(:render) > > Then, each of your tests set the actual should_receive expectation. > > -Corey > > On Fri, Mar 14, 2008 at 8:44 AM, Alan Larkin <[EMAIL PROTECTED] > <mailto:[EM

[rspec-users] Multiple should_receive(:render).with

2008-03-14 Thread Alan Larkin
I'm trying to specify that a particular view must render two different partials. My spec looks like: describe AClass do it do template.should_receive(:render).with(:partial => 'foo', :locals => { ... }) ... end describe 'some conditional case' do it do template.s