moses.hohman at gmail.com
Mon Jun 4 10:50:27 EDT 2007
What we usually do in this case is render the view with the layout and then
check the contents of the sidebar div. However, this does lead to having to
stub out additional things you don't care about in your example. If anyone
has a better plan I'd like to know, too.
On 6/4/07, Carl-Johan Kihlbom <kihlbom at gmail.com> wrote:
> On 5/23/07, Kyle Hargraves <philodespotos at gmail.com> wrote:
> > Any ideas how I would go about writing specs for views which make use
> > of content_for?
> > I'd like, for example, to be able to specify that ABC view places XYZ
> > in the sidebar, which I do using content_for(:sidebar).
> > Am I missing something obvious?
> > Kyle
> I have the same problem, several of my views use content_for to
> populate a sidebar. How can I write examples for them?
> / CJ
> rspec-users mailing list
> rspec-users at rubyforge.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the rspec-users