From: Bjørn Erik Pedersen Date: Sat, 15 Oct 2016 13:29:17 +0000 (+0200) Subject: Make the pygments shortcode test matching less specific X-Git-Tag: v0.18~191 X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=2e0e77bed1b3c220f3e131bdd942609c7deabcf6;p=brevno-suite%2Fhugo Make the pygments shortcode test matching less specific So it does not fail on "other" pygments versions. --- diff --git a/hugolib/shortcode_test.go b/hugolib/shortcode_test.go index 040dacd3..2ac52510 100644 --- a/hugolib/shortcode_test.go +++ b/hugolib/shortcode_test.go @@ -519,7 +519,7 @@ e`, // #2223 pygments {"sect/doc6.md", "\n```bash\nb: {{< b >}} c: {{% c %}}\n```\n", filepath.FromSlash("sect/doc6/index.html"), - "
b: b c: c\n
\n"}, + "b: b c: c\n\n"}, // #2249 {"sect/doc7.ad", `_Shortcodes:_ *b: {{< b >}} c: {{% c %}}*`, filepath.FromSlash("sect/doc7/index.html"), @@ -612,7 +612,7 @@ tags: content := helpers.ReaderToString(file) - if content != test.expected { + if !strings.Contains(content, test.expected) { t.Fatalf("%s content expected:\n%q\ngot:\n%q", test.outFile, test.expected, content) } }