search for: be_a

Displaying 3 results from an estimated 3 matches for "be_a".

Did you mean: be_
2007 Mar 28
3
respond.should be_successful
I''m wondering: Does it make more sense to add on successful? as an alias for success? in ActionController:TestRequest? I keep getting these two mixed up in my specs and was wondering if it would be helpful to anyone as a small patch to rspec. Best, Scott
2012 Nov 12
7
RSpec: controller POST create
...39;t quite understand tests for POST create part. I have generated scaffold, and simultaneously it generated controller_spec.rb as well. it "assigns a newly created plan as @plan" do post :create, {:plan => valid_attributes}, valid_session assigns(:plan).should be_a(Plan) assigns(:plan).should be_persisted end is the default POST create test. It raises a failure, if I changed the validations of Plan class Plan < ActiveRecord::Base validates :give_take, :presence => true validates :flight_name_id, :presence => true...
2011 Sep 07
4
rspec testing inheritance
Hello, Is there any way to test model inheritance in spec? something like.. it { ChildModel.should < ParentModel } thanks.