Skip to content

Commit 2d95ac5

Browse files
committed
Debug in progress
1 parent f4de26b commit 2d95ac5

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

cardano-chain-gen/test/Test/Cardano/Db/Mock/Config.hs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,8 @@ import System.Directory (createDirectoryIfMissing, removePathForcibly)
105105
import System.FilePath.Posix (takeDirectory, (</>))
106106
import System.IO.Silently (hSilence)
107107

108+
import Debug.Trace as Trace
109+
108110
data Config = Config
109111
{ topLevelConfig :: TopLevelConfig CardanoBlock
110112
, protocolInfo :: Consensus.ProtocolInfo CardanoBlock
@@ -474,7 +476,8 @@ withCustomConfigAndDropDB ::
474476
IOManager ->
475477
[(Text, Text)] ->
476478
IO a
477-
withCustomConfigAndDropDB =
479+
withCustomConfigAndDropDB = do
480+
Trace.traceM "withCustomConfigAndDropDB: Start"
478481
withFullConfig'
479482
( WithConfigArgs
480483
{ hasFingerprint = True
@@ -540,6 +543,7 @@ withFullConfig' ::
540543
[(Text, Text)] ->
541544
IO a
542545
withFullConfig' WithConfigArgs {..} cmdLineArgs mSyncNodeConfig configFilePath testLabelFilePath action iom migr = do
546+
Trace.traceM "withFullConfig': Start"
543547
recreateDir mutableDir
544548
-- check if custom syncNodeConfigs have been passed or not
545549
syncNodeConfig <-

cardano-chain-gen/test/Test/Cardano/Db/Mock/Unit/Conway/Config/JsonbInSchema.hs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,11 @@ import Test.Cardano.Db.Mock.Config
1616
import Test.Cardano.Db.Mock.Validate
1717
import Test.Tasty.HUnit (Assertion ())
1818

19+
import Debug.Trace as Trace
20+
1921
configRemoveJsonbFromSchemaEnabled :: IOManager -> [(Text, Text)] -> Assertion
2022
configRemoveJsonbFromSchemaEnabled = do
23+
Trace.traceM "configRemoveJsonbFromSchemaEnabled: Outside"
2124
withCustomConfigAndDropDB args (Just configRemoveJsonFromSchema) cfgDir testLabel $ \_interpreter _mockServer dbSync -> do
2225
startDBSync dbSync
2326
threadDelay 7_000_000
@@ -27,6 +30,7 @@ configRemoveJsonbFromSchemaEnabled = do
2730
False
2831
"There should be no jsonb data types in database if option is enabled"
2932
checkStillRuns dbSync
33+
Trace.traceM "configRemoveJsonbFromSchemaEnabled: End"
3034
where
3135
args = initCommandLineArgs {claFullMode = False}
3236
testLabel = "conwayConfigRemoveJsonbFromSchemaEnabled"
@@ -37,6 +41,7 @@ configRemoveJsonbFromSchemaDisabled :: IOManager -> [(Text, Text)] -> Assertion
3741
configRemoveJsonbFromSchemaDisabled = do
3842
withCustomConfigAndDropDB args (Just configRemoveJsonFromSchemaFalse) cfgDir testLabel $
3943
\_interpreter _mockServer dbSync -> do
44+
Trace.traceM "configRemoveJsonbFromSchemaDisabled A"
4045
startDBSync dbSync
4146
threadDelay 7_000_000
4247
assertEqQuery

0 commit comments

Comments
 (0)