Merge pull request #459 from joncfoo/patch-1

Fix code example in haddock  of servant-mock
This commit is contained in:
Sönke Hahn 2016-04-11 23:01:06 +08:00
commit fffa72b62b

View file

@ -36,7 +36,7 @@
-- and call 'mock', which has the following type:
--
-- @
-- 'mock' :: 'HasMock' api => 'Proxy' api -> 'Server' api
-- 'mock' :: 'HasMock' api context => 'Proxy' api -> 'Proxy' context -> 'Server' api
-- @
--
-- What this says is, given some API type @api@ that it knows it can
@ -52,7 +52,7 @@
-- @
-- main :: IO ()
-- main = Network.Wai.Handler.Warp.run 8080 $
-- 'serve' myAPI ('mock' myAPI)
-- 'serve' myAPI ('mock' myAPI Proxy)
-- @
module Servant.Mock ( HasMock(..) ) where
@ -90,7 +90,7 @@ class HasServer api context => HasMock api context where
-- -- let's say we will start with the frontend,
-- -- and hence need a placeholder server
-- server :: Server API
-- server = mock api
-- server = mock api Proxy
-- @
--
-- What happens here is that @'Server' API@