test extension match

This commit is contained in:
Tom Preston-Werner
2010-04-08 16:35:15 -07:00
parent a328e15dc3
commit 0a30b2ffc9
6 changed files with 6 additions and 1 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
module Gollum
class Page
VALID_PAGE_RE = /^(.+)\.(md|mkdn?|mdown|markdown|textile|rdoc|org|re?st(\.txt)?|asciidoc|pod|\d)$/
VALID_PAGE_RE = /^(.+)\.(md|mkdn?|mdown|markdown|textile|rdoc|org|re?st(\.txt)?|asciidoc|pod|\d)$/i
attr_accessor :wiki, :data
+1
View File
@@ -0,0 +1 @@
df26e61e707116f81ebc6b935ec6d1676b7e96c4
+4
View File
@@ -14,4 +14,8 @@ context "Page" do
test "no page match" do
assert_nil @wiki.formatted_page('I do not exist')
end
test "no ext match" do
assert_nil @wiki.formatted_page('Data')
end
end