Sha256: f4143c45df3d54d5faa155625543c2e7717fca1ad832000ad20e85a905deca32
Contents?: true
Size: 792 Bytes
Versions: 2
Compression:
Stored size: 792 Bytes
Contents
require 'spec_helper' shared_examples_for 'a described model' do # clazz must be defined by the calling file let(:model) { clazz.new } it 'has a description' do expect(model).to respond_to(:description) end it 'can change its description' do expect(model).to respond_to(:description=) model.description = :some_description expect(model.description).to eq(:some_description) model.description = :some_other_description expect(model.description).to eq(:some_other_description) end describe 'abstract instantiation' do context 'a new described object' do let(:model) { clazz.new } it 'starts with no description' do expect(model.description).to be_nil end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
cuke_modeler-1.0.1 | spec/unit/shared/described_models_unit_specs.rb |
cuke_modeler-1.0.0 | spec/unit/shared/described_models_unit_specs.rb |