From 2cf3882c4b455abba8aebf7c5bc66e3720ca1598 Mon Sep 17 00:00:00 2001 From: Sam Truzjan Date: Wed, 19 Feb 2014 05:16:36 +0400 Subject: Add spec for isActive function --- tests/Network/KRPCSpec.hs | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'tests/Network') diff --git a/tests/Network/KRPCSpec.hs b/tests/Network/KRPCSpec.hs index e695a646..0a6dc8fb 100644 --- a/tests/Network/KRPCSpec.hs +++ b/tests/Network/KRPCSpec.hs @@ -25,6 +25,13 @@ opts = def { optQueryTimeout = 1 } spec :: Spec spec = do + describe "manager" $ do + it "is active until closeManager called" $ do + m <- newManager opts servAddr [] + isActive m `shouldReturn` True + closeManager m + isActive m `shouldReturn` False + describe "query" $ do it "run handlers" $ do let int = 0xabcd :: Int -- cgit v1.2.3