sydtest-0.0.0.0: An advanced modern testing framework for Haskell with good defaults and advanced testing features.
Safe HaskellNone
LanguageHaskell2010

Test.Syd.Def.TestDefM

Synopsis

Documentation

type Spec = SpecWith () Source #

A synonym for easy migration from hspec

type SpecWith a = SpecM a () Source #

A synonym for easy migration from hspec

type SpecM a b = TestDefM '[] a b Source #

A synonym for easy migration from hspec

type TestDef a b = TestDefM a b () Source #

A synonym for a test suite definition

newtype TestDefM a b c Source #

The test definition monad

This type has three parameters:

  • a: The type of the result of aroundAll
  • b: The type of the result of around
  • c: The result

In practice, all of these three parameters should be () at the top level.

Constructors

TestDefM 

Instances

Instances details
MonadReader TestRunSettings (TestDefM a b) Source # 
Instance details

Defined in Test.Syd.Def.TestDefM

Methods

ask :: TestDefM a b TestRunSettings #

local :: (TestRunSettings -> TestRunSettings) -> TestDefM a b a0 -> TestDefM a b a0 #

reader :: (TestRunSettings -> a0) -> TestDefM a b a0 #

MonadState () (TestDefM a b) Source # 
Instance details

Defined in Test.Syd.Def.TestDefM

Methods

get :: TestDefM a b () #

put :: () -> TestDefM a b () #

state :: (() -> (a0, ())) -> TestDefM a b a0 #

Monad (TestDefM a b) Source # 
Instance details

Defined in Test.Syd.Def.TestDefM

Methods

(>>=) :: TestDefM a b a0 -> (a0 -> TestDefM a b b0) -> TestDefM a b b0 #

(>>) :: TestDefM a b a0 -> TestDefM a b b0 -> TestDefM a b b0 #

return :: a0 -> TestDefM a b a0 #

Functor (TestDefM a b) Source # 
Instance details

Defined in Test.Syd.Def.TestDefM

Methods

fmap :: (a0 -> b0) -> TestDefM a b a0 -> TestDefM a b b0 #

(<$) :: a0 -> TestDefM a b b0 -> TestDefM a b a0 #

Applicative (TestDefM a b) Source # 
Instance details

Defined in Test.Syd.Def.TestDefM

Methods

pure :: a0 -> TestDefM a b a0 #

(<*>) :: TestDefM a b (a0 -> b0) -> TestDefM a b a0 -> TestDefM a b b0 #

liftA2 :: (a0 -> b0 -> c) -> TestDefM a b a0 -> TestDefM a b b0 -> TestDefM a b c #

(*>) :: TestDefM a b a0 -> TestDefM a b b0 -> TestDefM a b b0 #

(<*) :: TestDefM a b a0 -> TestDefM a b b0 -> TestDefM a b a0 #

MonadIO (TestDefM a b) Source # 
Instance details

Defined in Test.Syd.Def.TestDefM

Methods

liftIO :: IO a0 -> TestDefM a b a0 #

MonadWriter (TestForest a b) (TestDefM a b) Source # 
Instance details

Defined in Test.Syd.Def.TestDefM

Methods

writer :: (a0, TestForest a b) -> TestDefM a b a0 #

tell :: TestForest a b -> TestDefM a b () #

listen :: TestDefM a b a0 -> TestDefM a b (a0, TestForest a b) #

pass :: TestDefM a b (a0, TestForest a b -> TestForest a b) -> TestDefM a b a0 #