On Feb 4, 2008 9:44 PM, Brian Rowe <[EMAIL PROTECTED]> wrote: > I'm looking for a working example of a put :update on a controller. The > documentation online avoids the update function. > > Any help pointing to this example would be great. Trying to get to 100% > coverage...can't make it without update :)
This is what I do: it "should replace foo with bar partial" do page = mock("page") page.should_receive(:replace_html).with('foo', :partial => 'bar') controller.expect_render(:update).and_yield(page) do_post end HTH, David > > Brian > > > _______________________________________________ > rspec-users mailing list > rspec-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users > _______________________________________________ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users