Update tests to work with Jekyll 3

This commit is contained in:
Pat Hawks 2016-02-02 20:02:08 -08:00
parent 6d2f5aee1b
commit a42df44513
No known key found for this signature in database
GPG Key ID: F1746FF5F18B3D1B
1 changed files with 4 additions and 2 deletions

View File

@ -26,8 +26,10 @@ def page(options={})
end
def post(options={})
page = Jekyll::Post.new site, CONFIG_DEFAULTS["source"], "", "2015-01-01-post.md"
page.data = options
filename = File.expand_path("2015-01-01-post.md", CONFIG_DEFAULTS["source"])
config = { :site => site, :collection => site.collections["posts"] }
page = Jekyll::Document.new filename, config
page.merge_data!(options)
page
end