Closed jmooring closed 5 days ago
Reference: https://discourse.gohugo.io/t/52431
The test below passes with v0.124.1, and fails with v0.125.0 and later.
func TestFoo(t *testing.T) { t.Parallel() files := ` -- hugo.toml -- disableKinds = ['section','rss','sitemap','taxonomy','term'] -- layouts/_default/home.html -- {{ .Content }} -- layouts/_default/single.html -- {{ .Content }} -- layouts/shortcodes/include.html -- {{ with site.GetPage (.Get 0) }} {{ .RenderShortcodes }} {{ end }} -- content/_index.md -- --- title: home --- a {{% include "/snippet" %}} b -- content/snippet.md -- --- title: snippet build: render: never list: never --- _emphasized_ ` b := hugolib.Test(t, files) b.AssertFileContentEquals("public/index.html", "<p>a</p>\n<p><em>emphasized</em></p>\n<p>b</p>\n", ) }
got:
"<p>a</p>\n<p></p>\n<p><em>emphasized</em>\n</p>\n<p>b</p>\n" ------- --
want:
"<p>a</p>\n<p><em>emphasized</em></p>\n<p>b</p>\n"
Reference: https://discourse.gohugo.io/t/52431
The test below passes with v0.124.1, and fails with v0.125.0 and later.
got:
want: