Module: RSpec::Rails::Extensions::ActiveRecord
- Included in:
- ActiveRecord::Base
- Defined in:
- lib/rspec/rails/extensions/active_record/base.rb
Instance Method Summary collapse
-
#records ⇒ Object
(also: #record)
:call-seq: ModelClass.should have(:no).records ModelClass.should have(1).record ModelClass.should have(n).records.
Instance Method Details
#records ⇒ Object Also known as: record
:call-seq:
ModelClass.should have(:no).records
ModelClass.should have(1).record
ModelClass.should have(n).records
Extension to enhance should have
on AR Model classes
12 13 14 |
# File 'lib/rspec/rails/extensions/active_record/base.rb', line 12 def records find(:all) end |