### General ```ruby response.should be_valid response.should_not be_valid response.should be_success response.should be_redirect response.should redirect_to("path/to/action") response.should redirect_to("http://test.host/path/to/action") response.should redirect_to(:action => 'list') response.should render_template('list') response.should render_template('same_controller/list') response.should render_template('other_controller/list') # partials response.should render_template('_a_partial') response.should render_template('same_controller/_a_partial') response.should render_template('other_controller/_a_partial') ``` ### Routing ```ruby "path".should route_to(expected) # assumes GET { :get => "path" }.should route_to(expected) { :put => "path" }.should route_to(expected) { "path" }.should_not be_routable # assumes GET { :get => "path" }.should_not be_routable { :put => "path" }.should_not be_routable ``` ### Content ```ruby response.should have_tag("div", "some text") person_address_tag.should have_tag("input#person_address") # in a helper response.should have_tag("div#form") do with_tag("input#person_name[name=?]", "person[name]") end response.should have_tag("div#1") do without_tag("span", "some text that shouldn't be there") end response.should include_text("This text will be in the actual string") ``` ### Mail ```ruby response.should send_email(*args, &block) ```