Sha256: 106926dd2ff76fcfda9ac4759f72c37e82fa8edd6faf15aea39649e2ce843269

Contents?: true

Size: 527 Bytes

Versions: 2

Compression:

Stored size: 527 Bytes

Contents

describe Rollin::YearArchive do
  let (:article) { Rollin::Article.new('spec/fixtures/2013_05_01_My_first_post.mk') }
  subject (:month_archive) { Rollin::MonthArchive.new(2013, 05, [ article ]) }
  subject (:year_archive) { Rollin::YearArchive.new(2013, [ month_archive ]) }

  it 'tells the year' do
    year_archive.year.should == 2013
  end

  it 'has monthly archives' do
    year_archive.monthly_archive.size.should == 1
  end

  it 'has a list of articles' do
    year_archive.articles.first.should == article
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
rollin-0.0.14 spec/year_archive_spec.rb
rollin-0.0.13 spec/year_archive_spec.rb