diff --git a/hugolib/helpers_for_test.go b/hugolib/helpers_for_test.go index f7b1dc5fa..7c41376a5 100644 --- a/hugolib/helpers_for_test.go +++ b/hugolib/helpers_for_test.go @@ -1,7 +1,6 @@ package hugolib import ( - "bytes" "testing" "github.com/spf13/afero" @@ -79,15 +78,3 @@ func pageMust(p *Page, err error) *Page { } return p } - -func matchRender(t *testing.T, s *Site, p *Page, tmplName string, expected string) { - content := new(bytes.Buffer) - err := s.renderThing(p, tmplName, NopCloser(content)) - if err != nil { - t.Fatalf("Unable to render template.") - } - - if string(content.Bytes()) != expected { - t.Fatalf("Content did not match expected: %s. got: %s", expected, content) - } -} diff --git a/hugolib/site_test.go b/hugolib/site_test.go index e4f9fca04..5b1bb0df2 100644 --- a/hugolib/site_test.go +++ b/hugolib/site_test.go @@ -79,6 +79,18 @@ func NopCloser(w io.Writer) io.WriteCloser { return nopCloser{w} } +func matchRender(t *testing.T, s *Site, p *Page, tmplName string, expected string) { + content := new(bytes.Buffer) + err := s.renderThing(p, tmplName, NopCloser(content)) + if err != nil { + t.Fatalf("Unable to render template.") + } + + if string(content.Bytes()) != expected { + t.Fatalf("Content did not match expected: %s. got: %s", expected, content) + } +} + func TestRenderThing(t *testing.T) { tests := []struct { content string