Skip to content

Commit

Permalink
failing test when prune/consume flags set to false
Browse files Browse the repository at this point in the history
  • Loading branch information
Cmdv committed Aug 23, 2023
1 parent 4f3b562 commit e026be0
Showing 1 changed file with 15 additions and 2 deletions.
17 changes: 15 additions & 2 deletions cardano-chain-gen/test/Test/Cardano/Db/Mock/Unit/Babbage/Plutus.hs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,14 @@ import qualified Data.Map as Map
import Data.Text (Text)
import Ouroboros.Consensus.Cardano.Block (StandardBabbage)
import Ouroboros.Network.Block (genesisPoint)
import Test.Cardano.Db.Mock.Config (babbageConfigDir, startDBSync, withFullConfig)
import Test.Cardano.Db.Mock.Config (
CommandLineArgs (..),
babbageConfigDir,
initCommandLineArgs,
startDBSync,
withCustomConfig,
withFullConfig,
)
import Test.Cardano.Db.Mock.UnifiedApi (
fillUntilNextEpoch,
forgeNextAndSubmit,
Expand Down Expand Up @@ -137,9 +144,10 @@ failedScript =
where
testLabel = "failedScript"

-- TODO: Vince -- this test fails when there are no prune/consume flags
failedScriptFees :: IOManager -> [(Text, Text)] -> Assertion
failedScriptFees =
withFullConfig babbageConfigDir testLabel $ \interpreter mockServer dbSync -> do
withCustomConfig cmdLineArgs babbageConfigDir testLabel $ \interpreter mockServer dbSync -> do
startDBSync dbSync

tx0 <- withBabbageLedgerState interpreter $ Babbage.mkLockByScriptTx (UTxOIndex 0) [Babbage.TxOutNoInline False] 20000 20000
Expand All @@ -154,6 +162,11 @@ failedScriptFees =
assertAlonzoCounts dbSync (0, 0, 0, 0, 1, 0, 1, 1)
assertNonZeroFeesContract dbSync
where
cmdLineArgs =
initCommandLineArgs
{ claMigrateConsumed = True
, claPruneTxOut = True
}
testLabel = "failedScriptFees"

failedScriptSameBlock :: IOManager -> [(Text, Text)] -> Assertion
Expand Down

0 comments on commit e026be0

Please sign in to comment.