@@ -299,6 +299,11 @@ func TestExtractFrontMatterDelim(t *testing.T) {
299299 // Issue #3511
300300 {`{ "title": "{" }` , `{ "title": "{" }` , noErrExpected },
301301 {`{ "title": "{}" }` , `{ "title": "{}" }` , noErrExpected },
302+ // Issue #3661
303+ {`{ "title": "\"" }` , `{ "title": "\"" }` , noErrExpected },
304+ {`{ "title": "\"{", "other": "\"{}" }` , `{ "title": "\"{", "other": "\"{}" }` , noErrExpected },
305+ {`{ "title": "\"Foo\"" }` , `{ "title": "\"Foo\"" }` , noErrExpected },
306+ {`{ "title": "\"Foo\"\"" }` , `{ "title": "\"Foo\"\"" }` , noErrExpected },
302307 }
303308
304309 for i , test := range tests {
@@ -310,7 +315,7 @@ func TestExtractFrontMatterDelim(t *testing.T) {
310315 }
311316 if ! bytes .Equal (fm , []byte (test .extracted )) {
312317 t .Logf ("\n %q\n " , string (test .frontmatter ))
313- t .Errorf ("[%d] Frontmatter did not match:\n exp: %q\n got: %q" , i , string (test .extracted ), fm )
318+ t .Errorf ("[%d] Frontmatter did not match:\n exp: %q\n got: %q" , i , string (test .extracted ), fm )
314319 }
315320 }
316321}
0 commit comments