mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-10 19:54:08 +02:00
tpl: Add test for recent template selection regression
Closes #13868 Co-authored-by: Joe Mooring <joe.mooring@veriphor.com>
This commit is contained in:
@@ -1603,3 +1603,24 @@ a|b
|
|||||||
b.AssertFileContent("public/index.html", "<table>")
|
b.AssertFileContent("public/index.html", "<table>")
|
||||||
b.AssertFileContent("public/index.json", "<table>")
|
b.AssertFileContent("public/index.json", "<table>")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func TestPageKindIssue13868(t *testing.T) {
|
||||||
|
t.Parallel()
|
||||||
|
|
||||||
|
files := `
|
||||||
|
-- hugo.toml --
|
||||||
|
disableKinds = ['home','rss','section','sitemap','taxonomy','term']
|
||||||
|
-- content/p1.md --
|
||||||
|
---
|
||||||
|
title: p1
|
||||||
|
---
|
||||||
|
-- layouts/page.html --
|
||||||
|
layouts/page.html
|
||||||
|
-- layouts/p1/page.html --
|
||||||
|
layouts/p1/page.html
|
||||||
|
`
|
||||||
|
|
||||||
|
b := hugolib.Test(t, files)
|
||||||
|
|
||||||
|
b.AssertFileContent("public/p1/index.html", "layouts/p1/page.html")
|
||||||
|
}
|
||||||
|
Reference in New Issue
Block a user