test/lib/vedeu/support/sentence_test.rb in vedeu-0.2.12 vs test/lib/vedeu/support/sentence_test.rb in vedeu-0.3.0
- old
+ new
@@ -2,17 +2,19 @@
module Vedeu
describe Sentence do
- let(:described) { Sentence.new(elements, label) }
+ let(:described) { Vedeu::Sentence }
+ let(:instance) { described.new(elements, label) }
let(:elements) { ['Hydrogen'] }
let(:label) { 'elements' }
describe '#initialize' do
- it { return_type_for(described, Sentence) }
- it { assigns(described, '@elements', elements) }
- it { assigns(described, '@label', label) }
+ subject { instance }
+ it { subject.must_be_instance_of(Sentence) }
+ it { subject.instance_variable_get('@elements').must_equal(elements) }
+ it { subject.instance_variable_get('@label').must_equal(label) }
end
describe '.construct' do
subject { Sentence.construct(elements, label) }