hugo/template/bundle/path_seperators_windows_test.go
Noah Campbell 79d9f82e79 Code reorg, helpers.go has been decomposed.
It started with wanting to move templates in template bundles and the
rest followed.  I did my best to start grouping related functions
together, but there are some that I missed.  There is also the method
Urlize that seems to be a special function used in both worlds.  I'll
need to revisit this method.
2013-09-03 16:16:07 -07:00

18 lines
413 B
Go

package bundle
import (
"testing"
)
const (
win_base = "c:\\a\\windows\\path\\layout"
win_path = "c:\\a\\windows\\path\\layout\\sub1\\index.html"
)
func TestTemplatePathSeperator(t *testing.T) {
tmpl := new(GoHtmlTemplate)
if name := tmpl.generateTemplateNameFrom(win_base, win_path); name != "sub1/index.html" {
t.Fatalf("Template name incorrect. Expected: %s, Got: %s", "sub1/index.html", name)
}
}