mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-17 21:01:26 +02:00
Replace regexp based Chomp with builtin TrimRight
This commit is contained in:
@@ -835,9 +835,9 @@ func TestMarkdownify(t *testing.T) {
|
||||
func TestChomp(t *testing.T) {
|
||||
base := "\n This is\na story "
|
||||
for i, item := range []string{
|
||||
"\n",
|
||||
"\r",
|
||||
"\r\n",
|
||||
"\n", "\n\n",
|
||||
"\r", "\r\r",
|
||||
"\r\n", "\r\n\r\n",
|
||||
} {
|
||||
chomped, _ := Chomp(base + item)
|
||||
|
||||
|
Reference in New Issue
Block a user