mirror of
https://github.com/gohugoio/hugo.git
synced 2024-05-11 05:54:58 +00: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