hakyll/tests/Hakyll/Web/Util/Html/Tests.hs

23 lines
535 B
Haskell
Raw Normal View History

2011-06-05 21:13:11 +00:00
module Hakyll.Web.Util.Html.Tests
( tests
) where
import Test.Framework
import Test.HUnit hiding (Test)
import Hakyll.Web.Util.Html
import TestSuite.Util
tests :: [Test]
tests = concat
[ fromAssertions "stripTags"
[ "foo" @=? stripTags "<p>foo</p>"
, "foo bar" @=? stripTags "<p>foo</p> bar"
, "foo" @=? stripTags "<p>foo</p"
]
2011-11-25 22:05:50 +00:00
, fromAssertions "escapeHtml"
[ "Me &amp; Dean" @=? escapeHtml "Me & Dean"
, "&lt;img&gt;" @=? escapeHtml "<img>"
]
2011-06-05 21:13:11 +00:00
]