I'm trying to specify that an action should be rendered with a given layout
one particular spec.
What I've got at the moment is this.
it "should render with the grabber layout" do
controller.should_receive( :render ).with( :layout => "my_layout" )
do_get
end
This doesnt work even though this call to render is being executed.
render :layout => "my_layout"
Firstly I don't understand why this isn't working. I'm getting an object
inspect with this message at the end
expected :render with ({:layout=>"my_layout"}) but received it with (no
> args)
>
I'd really like to understand why this isn't working, but I don't really
like it anyway. I mean, I really want to spec that under a particular set
of conditions it renders with a given layout.
I can't imagine I'm the first person to come up against this one. How are
other people handling this?
Cheers
Daniel
_______________________________________________
rspec-users mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/rspec-users