Flowdock
method

its

Importance_1
RSpec latest stable (1.3.1) - 1 note - Class: Spec::Example::Subject::ExampleGroupMethods
its(attribute, &block) public

No documentation

This method has no description. You can help the RSpec community by adding new notes.

Show source
Register or log in to add new notes.
April 16, 2014
3 thanks

Sample

Here is a sample usage of its,

Code example

describe '#rate_for_date' do
  context 'with date with in the range' do
    subject do 
      FactoryGirl.build(:allocated_room_rate, 
          start_date: Time.zone.now, 
          end_date: 2.day.from_now, 
          price: 1000)
    end
    its(:daily_rate) { should == 500 }
  end
end