Stability | unstable |
---|---|
Safe Haskell | None |
Language | Haskell2010 |
Test.Hspec.Core
Contents
Description
Deprecated: use Test.Hspec.Core.Spec instead
Synopsis
- defaultParams :: Params
- safeEvaluateExample :: Example e => e -> Params -> (ActionWith (Arg e) -> IO ()) -> ProgressCallback -> IO (Either SomeException Result)
- context :: String -> SpecWith a -> SpecWith a
- parallel :: SpecWith a -> SpecWith a
- pending :: Expectation
- pendingWith :: String -> Expectation
- specify :: (HasCallStack, Example a) => String -> a -> SpecWith (Arg a)
- xcontext :: String -> SpecWith a -> SpecWith a
- xdescribe :: String -> SpecWith a -> SpecWith a
- xit :: (HasCallStack, Example a) => String -> a -> SpecWith (Arg a)
- xspecify :: (HasCallStack, Example a) => String -> a -> SpecWith (Arg a)
- fromSpecList :: [SpecTree a] -> SpecWith a
- mapSpecItem :: (ActionWith a -> ActionWith b) -> (Item a -> Item b) -> SpecWith a -> SpecWith b
- mapSpecItem_ :: (Item a -> Item a) -> SpecWith a -> SpecWith a
- mapSpecTree :: (SpecTree a -> SpecTree b) -> SpecWith a -> SpecWith b
- modifyParams :: (Params -> Params) -> SpecWith a -> SpecWith a
- runIO :: IO r -> SpecM a r
- runSpecM :: SpecWith a -> IO [SpecTree a]
- specGroup :: String -> [SpecTree a] -> SpecTree a
- specItem :: (HasCallStack, Example a) => String -> a -> SpecTree (Arg a)
- type ActionWith a = a -> IO ()
- class Example e where
- data FailureReason
- data Location = Location {}
- data LocationAccuracy
- data Params = Params {}
- type Progress = (Int, Int)
- type ProgressCallback = Progress -> IO ()
- data Result
- type Spec = SpecWith ()
- newtype SpecM a r = SpecM (WriterT [SpecTree a] IO r)
- type SpecWith a = SpecM a ()
- data Item a = Item {
- itemRequirement :: String
- itemLocation :: Maybe Location
- itemIsParallelizable :: Bool
- itemExample :: Params -> (ActionWith a -> IO ()) -> ProgressCallback -> IO (Either SomeException Result)
- type SpecTree a = Tree (ActionWith a) (Item a)
- data Tree c a
- describe :: String -> [SpecTree a] -> SpecTree a
- it :: Example a => String -> a -> SpecTree (Arg a)
Documentation
defaultParams :: Params #
safeEvaluateExample :: Example e => e -> Params -> (ActionWith (Arg e) -> IO ()) -> ProgressCallback -> IO (Either SomeException Result) #
pending :: Expectation #
pendingWith :: String -> Expectation #
fromSpecList :: [SpecTree a] -> SpecWith a #
mapSpecItem :: (ActionWith a -> ActionWith b) -> (Item a -> Item b) -> SpecWith a -> SpecWith b #
type ActionWith a = a -> IO () #
Minimal complete definition
Methods
evaluateExample :: e -> Params -> (ActionWith (Arg e) -> IO ()) -> ProgressCallback -> IO Result #
Instances
data FailureReason #
Instances
Eq FailureReason | |
Defined in Test.Hspec.Core.Example Methods (==) :: FailureReason -> FailureReason -> Bool # (/=) :: FailureReason -> FailureReason -> Bool # | |
Read FailureReason | |
Defined in Test.Hspec.Core.Example Methods readsPrec :: Int -> ReadS FailureReason # readList :: ReadS [FailureReason] # | |
Show FailureReason | |
Defined in Test.Hspec.Core.Example Methods showsPrec :: Int -> FailureReason -> ShowS # show :: FailureReason -> String # showList :: [FailureReason] -> ShowS # | |
NFData FailureReason | |
Defined in Test.Hspec.Core.Example Methods rnf :: FailureReason -> () # |
data LocationAccuracy #
Constructors
ExactLocation | |
BestEffort |
Instances
Eq LocationAccuracy | |
Defined in Test.Hspec.Core.Example Methods (==) :: LocationAccuracy -> LocationAccuracy -> Bool # (/=) :: LocationAccuracy -> LocationAccuracy -> Bool # | |
Read LocationAccuracy | |
Defined in Test.Hspec.Core.Example Methods readsPrec :: Int -> ReadS LocationAccuracy # readList :: ReadS [LocationAccuracy] # | |
Show LocationAccuracy | |
Defined in Test.Hspec.Core.Example Methods showsPrec :: Int -> LocationAccuracy -> ShowS # show :: LocationAccuracy -> String # showList :: [LocationAccuracy] -> ShowS # |
Constructors
Params | |
Fields |
type ProgressCallback = Progress -> IO () #
Instances
Eq Result | |
Read Result | |
Show Result | |
Exception Result | |
Defined in Test.Hspec.Core.Example Methods toException :: Result -> SomeException # fromException :: SomeException -> Maybe Result # displayException :: Result -> String # | |
Example Result | |
Defined in Test.Hspec.Core.Example Methods evaluateExample :: Result -> Params -> (ActionWith (Arg Result) -> IO ()) -> ProgressCallback -> IO Result # | |
Example (a -> Result) | |
Defined in Test.Hspec.Core.Example Methods evaluateExample :: (a -> Result) -> Params -> (ActionWith (Arg (a -> Result)) -> IO ()) -> ProgressCallback -> IO Result # | |
type Arg Result | |
Defined in Test.Hspec.Core.Example | |
type Arg (a -> Result) | |
Defined in Test.Hspec.Core.Example |
Constructors
Item | |
Fields
|
type SpecTree a = Tree (ActionWith a) (Item a) #
Instances
Functor (Tree c) | |
Foldable (Tree c) | |
Defined in Test.Hspec.Core.Tree Methods fold :: Monoid m => Tree c m -> m # foldMap :: Monoid m => (a -> m) -> Tree c a -> m # foldr :: (a -> b -> b) -> b -> Tree c a -> b # foldr' :: (a -> b -> b) -> b -> Tree c a -> b # foldl :: (b -> a -> b) -> b -> Tree c a -> b # foldl' :: (b -> a -> b) -> b -> Tree c a -> b # foldr1 :: (a -> a -> a) -> Tree c a -> a # foldl1 :: (a -> a -> a) -> Tree c a -> a # elem :: Eq a => a -> Tree c a -> Bool # maximum :: Ord a => Tree c a -> a # minimum :: Ord a => Tree c a -> a # | |
Traversable (Tree c) | |