Fix jekyll serve --limit_posts n failed

This commit is contained in:
uu59
2013-04-28 02:03:08 +09:00
parent 46ce757b71
commit ad2c706a34
2 changed files with 12 additions and 1 deletions

View File

@@ -68,5 +68,15 @@ class TestGeneratedSite < Test::Unit::TestCase
@site = Site.new(Jekyll.configuration)
end
end
should "ensure if limit_posts is a String (from CLI option)" do
clear_dest
stub(Jekyll).configuration do
Jekyll::Configuration::DEFAULTS.merge({'limit_posts' => "3"})
end
@site = Site.new(Jekyll.configuration)
assert_equal 3, @site.limit_posts
end
end
end