Sha256: c6dc5395b69149df43d776e010fb3684a5a027fca001bc54082a731cfd3c8b32
Contents?: true
Size: 384 Bytes
Versions: 25
Compression:
Stored size: 384 Bytes
Contents
shared_examples_for 'an abstract type' do context 'called on a subclass' do let(:object) { Class.new(described_class) } it { should be_instance_of(object) } end context 'called on the class' do let(:object) { described_class } specify do expect { subject } .to raise_error(NotImplementedError, "#{object} is an abstract type") end end end
Version data entries
25 entries across 25 versions & 2 rubygems