This project is archived and is in readonly mode.

#4931 ✓resolved
David Chelimsky

View Test Case _assigns is locked on first reference to _view

Reported by David Chelimsky | June 22nd, 2010 @ 04:15 PM

Example:

_view.stubs(:current_user).returns(@user)
@foo = 'bar'
render :template => "some/template.html.erb"

In this case, the @foo variable is expected to be available to the view, but it is not because _assigns gets passed in to the view when you reference _view.

I'll work up a patch for this in the next day or so.

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

People watching this ticket

Referenced by

Pages