Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- verifyAllTimeouts :: Show addr => Bool -> Trace (SimResult ()) [(Time, AbstractTransitionTrace addr)] -> All
- verifyTimeouts :: Maybe (AbstractState, Time) -> Bool -> [(Time, AbstractTransitionTrace addr)] -> Property
- data Timeouts = Timeouts {}
- ioTimeouts :: Timeouts
- simTimeouts :: Timeouts
- groupConns :: Ord addr => (a -> TransitionTrace' addr st) -> (Transition' st -> Bool) -> Trace r a -> Trace r [a]
- groupConnsEither :: Ord addr => (a -> TransitionTrace' addr st) -> (Transition' st -> Bool) -> Trace r (Either a b) -> Trace r (Either [a] b)
- type SimAddr = TestAddress SimAddr_
- type SimAddr_ = Int
- newtype TestAddr = TestAddr {}
- data TestProperty = TestProperty {
- tpProperty :: !Property
- tpNumberOfTransitions :: !(Sum Int)
- tpNumberOfConnections :: !(Sum Int)
- tpNumberOfPrunings :: !(Sum Int)
- tpNegotiatedDataFlows :: ![NegotiatedDataFlow]
- tpEffectiveDataFlows :: ![EffectiveDataFlow]
- tpTerminationTypes :: ![Maybe TerminationType]
- tpActivityTypes :: ![ActivityType]
- tpTransitions :: ![AbstractTransition]
- mkProperty :: TestProperty -> Property
- mkPropertyPruning :: TestProperty -> Property
- classifyNegotiatedDataFlow :: [AbstractTransition] -> NegotiatedDataFlow
- classifyEffectiveDataFlow :: [AbstractTransition] -> EffectiveDataFlow
- classifyTermination :: [AbstractTransition] -> Maybe TerminationType
- classifyActivityType :: [AbstractTransition] -> ActivityType
- classifyPrunings :: [Trace addr (ConnectionHandlerTrace prctl dataflow)] -> Sum Int
- classifyPruning :: Trace addr (ConnectionHandlerTrace prctl dataflow) -> Sum Int
- newtype ArbDataFlow = ArbDataFlow DataFlow
- data ActivityType
- data TerminationType
- data NegotiatedDataFlow
- data EffectiveDataFlow = EffectiveDataFlow DataFlow
- within_ :: Int -> Int -> String
- ppTransition :: AbstractTransition -> String
Documentation
verifyAllTimeouts :: Show addr => Bool -> Trace (SimResult ()) [(Time, AbstractTransitionTrace addr)] -> All Source #
:: Maybe (AbstractState, Time) | Map of first occurrence of a given tau state |
-> Bool | If running in Diffusion or not |
-> [(Time, AbstractTransitionTrace addr)] | Stream of abstract transitions for a given connection paired with the time it occurred |
-> Property |
ioTimeouts :: Timeouts Source #
Timeouts for IO
tests.
simTimeouts :: Timeouts Source #
Timeouts for IOSim
tests.
groupConns :: Ord addr => (a -> TransitionTrace' addr st) -> (Transition' st -> Bool) -> Trace r a -> Trace r [a] Source #
Groups TransitionTrace
to the same peerAddr.
groupConnsEither :: Ord addr => (a -> TransitionTrace' addr st) -> (Transition' st -> Bool) -> Trace r (Either a b) -> Trace r (Either [a] b) Source #
Like groupConns
but can be used to also interleave other types of events.
type SimAddr = TestAddress SimAddr_ Source #
The concrete address type used by simulations.
We use a wrapper for test addresses since the Arbitrary instance for Snocket.TestAddress only generates addresses between 1 and 4.
data TestProperty Source #
Test property together with classification.
TestProperty | |
|
Instances
Monoid TestProperty Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts mempty :: TestProperty # mappend :: TestProperty -> TestProperty -> TestProperty # mconcat :: [TestProperty] -> TestProperty # | |
Semigroup TestProperty Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts (<>) :: TestProperty -> TestProperty -> TestProperty # sconcat :: NonEmpty TestProperty -> TestProperty # stimes :: Integral b => b -> TestProperty -> TestProperty # | |
Show TestProperty Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts showsPrec :: Int -> TestProperty -> ShowS # show :: TestProperty -> String # showList :: [TestProperty] -> ShowS # |
mkProperty :: TestProperty -> Property Source #
classifyPrunings :: [Trace addr (ConnectionHandlerTrace prctl dataflow)] -> Sum Int Source #
classifyPruning :: Trace addr (ConnectionHandlerTrace prctl dataflow) -> Sum Int Source #
newtype ArbDataFlow Source #
Instances
Arbitrary ArbDataFlow Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts arbitrary :: Gen ArbDataFlow # shrink :: ArbDataFlow -> [ArbDataFlow] # | |
Show ArbDataFlow Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts showsPrec :: Int -> ArbDataFlow -> ShowS # show :: ArbDataFlow -> String # showList :: [ArbDataFlow] -> ShowS # |
data ActivityType Source #
IdleConn | |
ActiveConn | Active connections are once that reach any of the state:
|
Instances
Show ActivityType Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts showsPrec :: Int -> ActivityType -> ShowS # show :: ActivityType -> String # showList :: [ActivityType] -> ShowS # | |
Eq ActivityType Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts (==) :: ActivityType -> ActivityType -> Bool # (/=) :: ActivityType -> ActivityType -> Bool # |
data TerminationType Source #
Instances
Show TerminationType Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts showsPrec :: Int -> TerminationType -> ShowS # show :: TerminationType -> String # showList :: [TerminationType] -> ShowS # | |
Eq TerminationType Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts (==) :: TerminationType -> TerminationType -> Bool # (/=) :: TerminationType -> TerminationType -> Bool # |
data NegotiatedDataFlow Source #
NotNegotiated | |
NegotiatedDataFlow DataFlow | Negotiated value of |
Instances
Show NegotiatedDataFlow Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts showsPrec :: Int -> NegotiatedDataFlow -> ShowS # show :: NegotiatedDataFlow -> String # showList :: [NegotiatedDataFlow] -> ShowS # | |
Eq NegotiatedDataFlow Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts (==) :: NegotiatedDataFlow -> NegotiatedDataFlow -> Bool # (/=) :: NegotiatedDataFlow -> NegotiatedDataFlow -> Bool # |
data EffectiveDataFlow Source #
EffectiveDataFlow DataFlow | Unlike the negotiated |
Instances
Show EffectiveDataFlow Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts showsPrec :: Int -> EffectiveDataFlow -> ShowS # show :: EffectiveDataFlow -> String # showList :: [EffectiveDataFlow] -> ShowS # | |
Eq EffectiveDataFlow Source # | |
Defined in Ouroboros.Network.ConnectionManager.Test.Timeouts (==) :: EffectiveDataFlow -> EffectiveDataFlow -> Bool # (/=) :: EffectiveDataFlow -> EffectiveDataFlow -> Bool # |