packages feed

yesod-markdown 0.12.6.11 → 0.12.6.12

raw patch · 3 files changed

+17/−16 lines, 3 files

Files

CHANGELOG.md view
@@ -1,6 +1,10 @@-## [_Unreleased_](https://github.com/pbrisbin/yesod-markdown/compare/v0.12.6.11...main)+## [_Unreleased_](https://github.com/pbrisbin/yesod-markdown/compare/v0.12.6.12...main)  None++## [v0.12.6.12](https://github.com/pbrisbin/yesod-markdown/compare/v0.12.6.11...v0.12.6.12)++- Relax test assertion for change in xss-sanitize behavior.  ## [v0.12.6.11](https://github.com/pbrisbin/yesod-markdown/compare/v0.12.6.10...v0.12.6.11) 
test/Spec.hs view
@@ -30,20 +30,17 @@         let Right html = markdownToHtml markdown          let rendered = renderHtml html-        rendered `shouldBe` TL.concat-            [ "<h1 id=\"title\">Title</h1>"-            , "<ul>"-            , "<li>one</li>"-            , "<li>two</li>"-            , "<li>three</li>"-            , "</ul>"-            -- pandoc-2.2.3 changes quote escaping in a minor way that we don't-            -- care about. CPP is annoying, so let's just make the assertion-            -- dynamic-            , if "&#39;" `TL.isInfixOf` rendered-                then "\n  alert(&#39;xxs&#39;);\n"-                else "\n  alert('xxs');\n"-            ]+            expectedPrefix = mconcat+                [ "<h1 id=\"title\">Title</h1>"+                , "<ul>"+                , "<li>one</li>"+                , "<li>two</li>"+                , "<li>three</li>"+                , "</ul>"+                ]++        rendered `shouldSatisfy` (expectedPrefix `TL.isPrefixOf`)+        rendered `shouldSatisfy` (not . ("<script>" `TL.isInfixOf`))      it "converts Markdown to unsanitized HTML" $ do         let
yesod-markdown.cabal view
@@ -1,6 +1,6 @@ cabal-version:      1.12 name:               yesod-markdown-version:            0.12.6.11+version:            0.12.6.12 license:            GPL-2 license-file:       LICENSE maintainer:         Patrick Brisbin <pbrisbin@gmail.com>