The first page in an empty repository can now be previewed.

This commit is contained in:
Mihail Minkov
2011-09-27 18:52:51 +03:00
parent 7829e17c27
commit b8ce2b251d
16 changed files with 492 additions and 2 deletions
+11
View File
@@ -101,6 +101,17 @@ context "Frontend" do
assert last_response.ok?
end
test "previews content on the first page of an empty wiki" do
@path = cloned_testpath("examples/empty.git")
@wiki = Gollum::Wiki.new(@path)
Precious::App.set(:gollum_path, @path)
Precious::App.set(:wiki_options, {})
post "/preview", :content => 'abc', :format => 'markdown'
assert last_response.ok?
end
test "reverts single commit" do
page1 = @wiki.page('B')