Use Publisher instead of Post#published?

This commit is contained in:
maul.esel
2014-04-07 15:38:11 +02:00
parent 26663a6cf9
commit 3a330dc7fc
2 changed files with 7 additions and 5 deletions

View File

@@ -417,12 +417,12 @@ class TestPost < Test::Unit::TestCase
context "initializing posts" do
should "publish when published yaml is no specified" do
post = setup_post("2008-02-02-published.textile")
assert_equal true, post.published?
assert_equal true, @site.send(:publisher).publish?(post)
end
should "not published when published yaml is false" do
post = setup_post("2008-02-02-not-published.textile")
assert_equal false, post.published?
assert_equal false, @site.send(:publisher).publish?(post)
end
should "recognize date in yaml" do