[rspec-users] assign local variable instead of instance variable.
Hans de Graaff
hans at degraaff.org
Wed Aug 29 10:32:53 EDT 2007
On Wed, 2007-08-29 at 14:35 +0200, Mathias Stjernström wrote:
> And to describe that: http://pastie.textmate.org/91995
> The problem is that (assigns[:advert] = advert) creates an instance
> variable and :collection => @adverts creates a local variable called
> Is there a way of assigning a local variables in a view/template from
> my description/spec?
I'm using "render :partial => 'some_partial', :object => @mock_object"
in those cases.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://rubyforge.org/pipermail/rspec-users/attachments/20070829/0f4ae3fa/attachment.bin
More information about the rspec-users