Updating shortcode imports & site test to work with new buffer pool functions - hugo - [fork] hugo port for 9front
HTML git clone git@git.drkhsh.at/hugo.git
DIR Log
DIR Files
DIR Refs
DIR Submodules
DIR README
DIR LICENSE
---
DIR commit f4737689bd3d9f73129cf3615025aafb93d0efbe
DIR parent e1e6aaed2f57d682f99a478c5602117ae27707eb
HTML Author: spf13 <steve.francia@gmail.com>
Date: Sat, 31 Jan 2015 01:06:04 -0500
Updating shortcode imports & site test to work with new buffer pool functions
Diffstat:
M hugolib/shortcode.go | 1 -
M hugolib/site_test.go | 9 +++------
2 files changed, 3 insertions(+), 7 deletions(-)
---
DIR diff --git a/hugolib/shortcode.go b/hugolib/shortcode.go
@@ -14,7 +14,6 @@
package hugolib
import (
- "bytes"
"fmt"
"html/template"
"reflect"
DIR diff --git a/hugolib/site_test.go b/hugolib/site_test.go
@@ -178,19 +178,16 @@ func TestRenderThingOrDefault(t *testing.T) {
}
var err2 error
- var b io.Reader
+
if test.missing {
- b, err2 = s.renderPage("name", p, "missing", templateName)
+ err2 = s.renderAndWritePage("name", "out", p, "missing", templateName)
} else {
- b, err2 = s.renderPage("name", p, templateName, "missing_default")
+ err2 = s.renderAndWritePage("name", "out", p, templateName, "missing_default")
}
if err2 != nil {
t.Errorf("Unable to render html: %s", err)
}
- if err2 := s.WriteDestPage("out", b); err2 != nil {
- t.Errorf("Unable to write html: %s", err)
- }
file, err := hugofs.DestinationFS.Open(filepath.FromSlash("out/index.html"))
if err != nil {