{-# LANGUAGE OverloadedStrings #-}
{-# OPTIONS_HADDOCK prune not-home #-}
module Test.KeyedVals.Hspec (
checkHandle,
setupFixture,
closeFixture,
module Test.KeyedVals.Prelude,
) where
import qualified Test.KeyedVals.CheckHandle as LessTyped
import qualified Test.KeyedVals.CheckTypedHandle as Typed
import Test.KeyedVals.Prelude
checkHandle :: SpecWith (Handle IO)
checkHandle :: SpecWith (Handle IO)
checkHandle = do
SpecWith (Handle IO)
LessTyped.spec
SpecWith (Handle IO)
Typed.spec
setupFixture :: Handle IO -> IO (Handle IO)
setupFixture :: Handle IO -> IO (Handle IO)
setupFixture Handle IO
h = do
forall (f :: * -> *) a. Functor f => f a -> f ()
void forall a b. (a -> b) -> a -> b
$ Handle IO -> IO (Handle IO)
LessTyped.setupFixture Handle IO
h
forall (f :: * -> *) a. Functor f => f a -> f ()
void forall a b. (a -> b) -> a -> b
$ Handle IO -> IO (Handle IO)
Typed.setupFixture Handle IO
h
forall (f :: * -> *) a. Applicative f => a -> f a
pure Handle IO
h
closeFixture :: Handle IO -> IO ()
closeFixture :: Handle IO -> IO ()
closeFixture = forall (m :: * -> *). Handle m -> m ()
close