Skip to content

Commit

Permalink
Update test ChainDB construction
Browse files Browse the repository at this point in the history
  • Loading branch information
bartfrenk committed Feb 2, 2023
1 parent fc66f2d commit 01a08d4
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions ouroboros-consensus-test/src/Test/Util/ChainDB.hs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@ import Ouroboros.Consensus.Block.Abstract
import Ouroboros.Consensus.Config
(TopLevelConfig (topLevelConfigLedger),
configSecurityParam)
import Ouroboros.Consensus.Fragment.InFuture (CheckInFuture (..))
import qualified Ouroboros.Consensus.Fragment.Validated as VF
import Ouroboros.Consensus.Fragment.InFuture (dontCheck)
import Ouroboros.Consensus.HardFork.History.EraParams (EraParams,
eraEpochSize)
import Ouroboros.Consensus.Ledger.Basics (LedgerConfig)
Expand Down Expand Up @@ -103,7 +102,7 @@ fromMinimalChainDbArgs MinimalChainDbArgs {..} = ChainDbArgs {
-- ImmutableDB, as the VolatileDB. This is done in @extractBlockComponent@ in the iterator for the
-- ImmutableDB, and in @getBlockComponent@ for the VolatileDB.
, cdbGenesis = return mcdbInitLedger
, cdbCheckInFuture = CheckInFuture $ \vf -> pure (VF.validatedFragment vf, [])
, cdbCheckInFuture = dontCheck
-- Blocks are never in the future.
, cdbImmutableDbCacheConfig = ImmutableDB.CacheConfig 2 60
-- Cache at most 2 chunks and expire each chunk after 60 seconds of being unused.
Expand Down

0 comments on commit 01a08d4

Please sign in to comment.