diff options
Diffstat (limited to 'tests/Hakyll/Core/Routes/Tests.hs')
-rw-r--r-- | tests/Hakyll/Core/Routes/Tests.hs | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/tests/Hakyll/Core/Routes/Tests.hs b/tests/Hakyll/Core/Routes/Tests.hs index 4f975ae..5a833b0 100644 --- a/tests/Hakyll/Core/Routes/Tests.hs +++ b/tests/Hakyll/Core/Routes/Tests.hs @@ -6,15 +6,13 @@ module Hakyll.Core.Routes.Tests -------------------------------------------------------------------------------- -import qualified Data.Map as M +import Data.Maybe (fromMaybe) +import Hakyll.Core.Identifier +import Hakyll.Core.Metadata +import Hakyll.Core.Routes import System.FilePath ((</>)) import Test.Framework (Test, testGroup) import Test.HUnit (Assertion, (@=?)) - - --------------------------------------------------------------------------------- -import Hakyll.Core.Identifier -import Hakyll.Core.Routes import TestSuite.Util @@ -37,7 +35,7 @@ tests = testGroup "Hakyll.Core.Routes.Tests" $ fromAssertions "runRoutes" "tags/rss/bar" , testRoutes "food/example.md" (metadataRoute $ \md -> customRoute $ \id' -> - M.findWithDefault "?" "subblog" md </> toFilePath id') + fromMaybe "?" (lookupString "subblog" md) </> toFilePath id') "example.md" ] |