--------------------------------------------------------------------------------
{-# LANGUAGE OverloadedStrings #-}
module Hakyll.Web.Html.RelativizeUrls.Tests
( tests
) where
--------------------------------------------------------------------------------
import Test.Framework (Test, testGroup)
import Test.HUnit ((@=?))
--------------------------------------------------------------------------------
import Hakyll.Web.Html.RelativizeUrls
import TestSuite.Util
--------------------------------------------------------------------------------
tests :: Test
tests = testGroup "Hakyll.Web.Html.RelativizeUrls.Tests" $
fromAssertions "relativizeUrls"
[ "bar" @=?
relativizeUrlsWith ".." "bar"
, "" @=?
relativizeUrlsWith "../.." ""
, "" @=?
relativizeUrlsWith "../.."
""
, "Haskell" @=?
relativizeUrlsWith "../.."
"Haskell"
, "Haskell" @=?
relativizeUrlsWith "../.."
"Haskell"
, "" @=?
relativizeUrlsWith "../.."
""
]