Sha256: 5242ddc3c73f47d7baddf3d08d843e625eb860a885d26c5e81c4b98c79ce7de5
Contents?: true
Size: 417 Bytes
Versions: 96
Compression:
Stored size: 417 Bytes
Contents
it "create action should render new template when model is invalid" do <%= class_name %>.any_instance.stubs(:valid?).returns(false) post :create response.should render_template(:new) end it "create action should redirect when model is valid" do <%= class_name %>.any_instance.stubs(:valid?).returns(true) post :create response.should redirect_to(<%= item_path_for_spec('url') %>) end
Version data entries
96 entries across 65 versions & 14 rubygems