Introduce unit testing for page.go

This commit is contained in:
Noah Campbell
2013-08-04 19:02:15 -07:00
parent fa55cd9857
commit 274d324c8b
3 changed files with 24 additions and 9 deletions

View File

@@ -78,10 +78,9 @@ func (p Pages) Limit(n int) Pages { return p[0:n] }
func initializePage(filename string) (page Page) {
page = Page{contentType: "",
File: File{FileName: filename,
Extension: "html"},
File: File{FileName: filename, Extension: "html"},
Node: Node{Keywords: make([]string, 10, 30)},
Params: make(map[string]interface{}),
Node: Node{Keywords: make([]string, 10, 30)},
Markup: "md"}
page.Date, _ = time.Parse("20060102", "20080101")
page.setSection()