M example_test.go => example_test.go +2 -2
@@ 14,6 14,6 @@ func ExampleExtemplate_ParseDir() {
})
_ = xt.ParseDir("examples", []string{".tmpl"})
_ = xt.ExecuteTemplate(os.Stdout, "child.tmpl", nil)
- // Output: Hello from child.tmpl
- // Hello from partials/question.tmpl
+ /* Output: Hello from child.tmpl
+ Hello from partials/question.tmpl */
}
M template_test.go => template_test.go +1 -0
@@ 67,6 67,7 @@ func TestTemplates(t *testing.T) {
}
e := strings.TrimSpace(buf.String())
+ e = strings.Replace(e, "\r\n", "\n", -1)
if e != v {
t.Errorf("incorrect template result. \nExpected: %s\nActual: %s", v, e)
}