mirror of
https://github.com/gohugoio/hugo.git
synced 2025-04-07 10:07:38 +00:00
gofmt pass
Clean up test files.
This commit is contained in:
parent
2d11d1bd67
commit
5664780cca
2 changed files with 4 additions and 6 deletions
|
@ -23,10 +23,10 @@ func TestDegenerateMissingFolderInPageFilename(t *testing.T) {
|
||||||
}
|
}
|
||||||
|
|
||||||
func TestNewPageWithFilePath(t *testing.T) {
|
func TestNewPageWithFilePath(t *testing.T) {
|
||||||
toCheck := []struct{
|
toCheck := []struct {
|
||||||
input string
|
input string
|
||||||
section string
|
section string
|
||||||
layout string
|
layout string
|
||||||
}{
|
}{
|
||||||
{filepath.Join("sub", "foobar.html"), "sub", "sub/single.html"},
|
{filepath.Join("sub", "foobar.html"), "sub", "sub/single.html"},
|
||||||
{filepath.Join("content", "sub", "foobar.html"), "sub", "sub/single.html"},
|
{filepath.Join("content", "sub", "foobar.html"), "sub", "sub/single.html"},
|
||||||
|
@ -47,5 +47,3 @@ func TestNewPageWithFilePath(t *testing.T) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@ import (
|
||||||
func TestTemplatePathSeperator(t *testing.T) {
|
func TestTemplatePathSeperator(t *testing.T) {
|
||||||
config := Config{
|
config := Config{
|
||||||
LayoutDir: "c:\\a\\windows\\path\\layout",
|
LayoutDir: "c:\\a\\windows\\path\\layout",
|
||||||
Path: "c:\\a\\windows\\path",
|
Path: "c:\\a\\windows\\path",
|
||||||
}
|
}
|
||||||
s := &Site{Config: config}
|
s := &Site{Config: config}
|
||||||
if name := s.generateTemplateNameFrom("c:\\a\\windows\\path\\layout\\sub1\\index.html"); name != "sub1/index.html" {
|
if name := s.generateTemplateNameFrom("c:\\a\\windows\\path\\layout\\sub1\\index.html"); name != "sub1/index.html" {
|
||||||
|
|
Loading…
Add table
Reference in a new issue