From 45db2ba40f82176dcc731d3dc10d3a23eb2dc461 Mon Sep 17 00:00:00 2001 From: Tom Preston-Werner Date: Wed, 5 Nov 2008 22:05:24 -0500 Subject: [PATCH] fix layout tests --- test/test_post.rb | 4 ++-- test/test_site.rb | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/test/test_post.rb b/test/test_post.rb index 8b6d6c2d..89f32f4f 100644 --- a/test/test_post.rb +++ b/test/test_post.rb @@ -45,7 +45,7 @@ class TestPost < Test::Unit::TestCase def test_add_layout p = Post.new(File.join(File.dirname(__FILE__), *%w[source posts]), "2008-10-18-foo-bar.textile") - layouts = {"default" => "<<< {{ content }} >>>"} + layouts = {"default" => Layout.new(File.join(File.dirname(__FILE__), *%w[source _layouts]), "simple.html")} p.add_layout(layouts, {"site" => {"posts" => []}}) assert_equal "<<<

Foo Bar

\n\n\n\t

Best post ever

>>>", p.output @@ -55,7 +55,7 @@ class TestPost < Test::Unit::TestCase clear_dest p = Post.new(File.join(File.dirname(__FILE__), *%w[source posts]), "2008-10-18-foo-bar.textile") - layouts = {"default" => "<<< {{ content }} >>>"} + layouts = {"default" => Layout.new(File.join(File.dirname(__FILE__), *%w[source _layouts]), "simple.html")} p.add_layout(layouts, {"site" => {"posts" => []}}) p.write(dest_dir) end diff --git a/test/test_site.rb b/test/test_site.rb index 24f0582a..432f1b5c 100644 --- a/test/test_site.rb +++ b/test/test_site.rb @@ -13,7 +13,7 @@ class TestSite < Test::Unit::TestCase def test_read_layouts @s.read_layouts - assert_equal ["default"], @s.layouts.keys + assert_equal ["default", "simple"].sort, @s.layouts.keys.sort end def test_read_posts