ouroboros-network-framework:testlib
Safe HaskellNone
LanguageHaskell2010

Ouroboros.Network.ConnectionManager.Test.Utils

Synopsis

Documentation

validTransitionMap :: AbstractTransition -> (Int, String) Source #

Maps each valid transition into one number. Collapses all invalid transition into a single number.

NOTE: Should be in sync with verifyAbstractTransition

verifyAbstractTransitionOrder Source #

Arguments

:: Show a 
=> (a -> AbstractTransition) 
-> Bool

Check last transition: useful for distinguish Diffusion layer tests vs non-Diffusion ones.

-> [a] 
-> All 

allValidTransitionsNames :: [String] Source #

List of all valid transition's names.

NOTE: Should be in sync with verifyAbstractTransition, but due to #3516 abrupt terminating transitions and identity transitions are trimmed for now, until we tweak the generators to include more connection errors.

abstractStateIsFinalTransitionTVarTracing :: Transition' AbstractState -> Bool Source #

This function is necessary to check tests that only read from the traceTVar logging output. These traceTVar logs do not transition to UnknownConnectionSt.

connectionManagerTraceMap :: Trace ntnAddr (ConnectionHandlerTrace ntnVersion ntnVersionData) -> String Source #