@@ -41,6 +41,15 @@ case01 = do
41 >>= saveSnapshot "raw"
41 >>= saveSnapshot "raw"
42 >>= renderPandoc
42 >>= renderPandoc
44+ match (fromList ["partial.html", "partial-helper.html"]) $
45+ compile templateCompiler
46+ create ["partial.html.out"] $ do
49+ example <- loadSnapshotBody "example.md" "raw"
51+ >>= loadAndApplyTemplate "partial.html" defaultContext
44 create ["bodies.txt"] $ do
53 create ["bodies.txt"] $ do
45 route idRoute
54 route idRoute
46 compile $ do
55 compile $ do
@@ -60,6 +69,10 @@ case01 = do
60 bodies <- readFile $ destinationDirectory testConfiguration </> "bodies.txt"
69 bodies <- readFile $ destinationDirectory testConfiguration </> "bodies.txt"
61 head (lines bodies) @?= "This is an example."
70 head (lines bodies) @?= "This is an example."
72+ partial <- readFile $ providerDirectory testConfiguration </> "partial.html.out"
73+ partial' <- readFile $ destinationDirectory testConfiguration </> "partial.html.out"
63 cleanTestEnv
76 cleanTestEnv