stub of Repo#formatted_page
This commit is contained in:
@@ -3,6 +3,7 @@ require 'grit'
|
|||||||
|
|
||||||
# internal
|
# internal
|
||||||
require 'gollum/repo'
|
require 'gollum/repo'
|
||||||
|
require 'gollum/page'
|
||||||
|
|
||||||
module Gollum
|
module Gollum
|
||||||
VERSION = '0.0.1'
|
VERSION = '0.0.1'
|
||||||
|
|||||||
@@ -0,0 +1,5 @@
|
|||||||
|
module Gollum
|
||||||
|
class Page
|
||||||
|
|
||||||
|
end
|
||||||
|
end
|
||||||
@@ -11,5 +11,14 @@ module Gollum
|
|||||||
self.path = path
|
self.path = path
|
||||||
self.repo = Grit::Repo.new(path)
|
self.repo = Grit::Repo.new(path)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# Get the formatted page for a given page name.
|
||||||
|
#
|
||||||
|
# name - The String name of the wiki page.
|
||||||
|
#
|
||||||
|
# Returns a Gollum::Page or nil if no matching page was found.
|
||||||
|
def formatted_page(name)
|
||||||
|
Page.new()
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
require 'helper'
|
||||||
|
|
||||||
|
context "Page" do
|
||||||
|
setup do
|
||||||
|
@repo = Gollum::Repo.new("examples/lotr.git")
|
||||||
|
end
|
||||||
|
|
||||||
|
test "formatted page" do
|
||||||
|
page = @repo.formatted_page('Bilbo-Baggins')
|
||||||
|
end
|
||||||
|
end
|
||||||
Reference in New Issue
Block a user