ouroboros-consensus-test-0.1.0.0: Tests of the consensus layer
Safe HaskellNone
LanguageHaskell2010

Test.Util.ChainDB

Synopsis

Documentation

data MinimalChainDbArgs m blk Source #

Minimal set of arguments for creating a ChainDB instance for testing purposes.

Constructors

MinimalChainDbArgs 

Fields

data NodeDBs db Source #

A vector with an element for each database of a node

The db type parameter is instantiated by this module at types for mock filesystems; either the MockFS type or reference cells thereof.

Constructors

NodeDBs 

Fields

Instances

Instances details
Functor NodeDBs Source # 
Instance details

Defined in Test.Util.ChainDB

Methods

fmap ∷ (a → b) → NodeDBs a → NodeDBs b Source #

(<$) ∷ a → NodeDBs b → NodeDBs a Source #

Foldable NodeDBs Source # 
Instance details

Defined in Test.Util.ChainDB

Methods

foldMonoid m ⇒ NodeDBs m → m Source #

foldMapMonoid m ⇒ (a → m) → NodeDBs a → m Source #

foldMap'Monoid m ⇒ (a → m) → NodeDBs a → m Source #

foldr ∷ (a → b → b) → b → NodeDBs a → b Source #

foldr' ∷ (a → b → b) → b → NodeDBs a → b Source #

foldl ∷ (b → a → b) → b → NodeDBs a → b Source #

foldl' ∷ (b → a → b) → b → NodeDBs a → b Source #

foldr1 ∷ (a → a → a) → NodeDBs a → a Source #

foldl1 ∷ (a → a → a) → NodeDBs a → a Source #

toListNodeDBs a → [a] Source #

nullNodeDBs a → Bool Source #

lengthNodeDBs a → Int Source #

elemEq a ⇒ a → NodeDBs a → Bool Source #

maximumOrd a ⇒ NodeDBs a → a Source #

minimumOrd a ⇒ NodeDBs a → a Source #

sumNum a ⇒ NodeDBs a → a Source #

productNum a ⇒ NodeDBs a → a Source #

Traversable NodeDBs Source # 
Instance details

Defined in Test.Util.ChainDB

Methods

traverseApplicative f ⇒ (a → f b) → NodeDBs a → f (NodeDBs b) Source #

sequenceAApplicative f ⇒ NodeDBs (f a) → f (NodeDBs a) Source #

mapMMonad m ⇒ (a → m b) → NodeDBs a → m (NodeDBs b) Source #

sequenceMonad m ⇒ NodeDBs (m a) → m (NodeDBs a) Source #

fromMinimalChainDbArgs ∷ (MonadThrow m, MonadSTM m, ConsensusProtocol (BlockProtocol blk)) ⇒ MinimalChainDbArgs m blk → ChainDbArgs Identity m blk Source #

Creates a default set of of arguments for ChainDB tests.

mkTestChunkInfoLedgerConfig blk ~ EraParamsTopLevelConfig blk → ChunkInfo Source #

Utility function to get a default chunk info in case we have EraParams available.