[rspec-users] Scaffold views spec failing
ben rooney
ben.rooney62 at googlemail.com
Thu Apr 8 16:34:11 EDT 2010
Obviously my noooooob question was embarrassingly noob - so I was
forced to actually do some work and answer my own questions.
The answer was that I had to stub out the association - natch...
before(:each) do
assigns[:tipes] = [
stub_model(Tipe,
:name => "value for name",
:live => true,
:category => stub_model(Category,
:name =>"category",
:live => true,
:id => 1)
),
stub_model(Tipe,
:name => "value for name",
:live => true,
:category => stub_model(Category,
:name =>"category",
:live => true,
:id => 1)
)
]
And lo - it all works! Hurrah. So if anyone else is as much as an
idiot as me (unlikely, but you never know) that is what you do.
Ben
More information about the rspec-users
mailing list