spec/signore/signature_spec.rb in signore-0.2.0 vs spec/signore/signature_spec.rb in signore-0.2.1

- old
+ new

@@ -5,22 +5,23 @@ it 'instantiates Signatures via parameters' do source = 'A History of Modern Computing' text = 'In 1940 he summarized his work in an influential book, ' \ '‘Punched Card Methods in Scientific Computation’.' sig = Signature[author: 'Paul E. Ceruzzi', source: source, - subject: 'on Wallace Eckert', tags: ['punched cards'], text: text] + subject: 'on Wallace Eckert', tags: ['punched cards'], + text: text] sig.author.must_equal 'Paul E. Ceruzzi' sig.source.must_equal source sig.subject.must_equal 'on Wallace Eckert' sig.tags.must_equal ['punched cards'] sig.text.must_equal text end end describe '#tagged_with?' do it 'says whether a tagged signature is tagged with a given tag' do - sig = Signature[tags: %w[programming tech]] + sig = Signature[tags: %w(programming tech)] refute sig.tagged_with? 'fnord' assert sig.tagged_with? 'programming' assert sig.tagged_with? 'tech' end @@ -64,10 +65,10 @@ it 'shows author and subject, space separated' do text = 'She was good at playing abstract confusion ' \ 'in the same way a midget is good at being short.' sig = Signature[text: text, author: 'Clive James', - subject: 'on Marilyn Monroe'] + subject: 'on Marilyn Monroe'] sig.to_s.must_equal <<-end.dedent.strip She was good at playing abstract confusion in the same way a midget is good at being short. [Clive James on Marilyn Monroe] end