mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-20 21:31:32 +02:00
committed by
Bjørn Erik Pedersen
parent
883e71c96a
commit
e46e9ceb29
@@ -394,3 +394,32 @@ FENCE
|
||||
builders[i].Build()
|
||||
}
|
||||
}
|
||||
|
||||
// Issue 9594
|
||||
func TestQuotesInImgAltAttr(t *testing.T) {
|
||||
t.Parallel()
|
||||
|
||||
files := `
|
||||
-- config.toml --
|
||||
[markup.goldmark.extensions]
|
||||
typographer = false
|
||||
-- content/p1.md --
|
||||
---
|
||||
title: "p1"
|
||||
---
|
||||

|
||||
-- layouts/_default/single.html --
|
||||
{{ .Content }}
|
||||
`
|
||||
|
||||
b := hugolib.NewIntegrationTestBuilder(
|
||||
hugolib.IntegrationTestConfig{
|
||||
T: t,
|
||||
TxtarString: files,
|
||||
},
|
||||
).Build()
|
||||
|
||||
b.AssertFileContent("public/p1/index.html", `
|
||||
<img src="b.jpg" alt=""a"">
|
||||
`)
|
||||
}
|
||||
|
Reference in New Issue
Block a user