Skip to content

Commit 0259817

Browse files
cootcrocodile-dentist
authored andcommitted
cardano-diffusion package
Introduced `cardano-diffusion` package. Some things are hidden inside of it because that's how we are testing things now, in particular `PeerSelection` and `Testnet` tests depend on `Cardano` constructs. In the future we could split them into general test & cardano specific tests, this will be in particularly useful for another non-trivial extension of `ouroboros-network`, but also might organise tests better.
1 parent df95051 commit 0259817

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

dmq-node/src/DMQ/Diffusion/Arguments.hs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@ diffusionArguments
5050
=> Tracer m (NtN.HandshakeTr ntnAddr)
5151
-> Tracer m (NtC.HandshakeTr ntcAddr)
5252
-> Diffusion.Arguments
53-
NoExtraState NoExtraDebugState NoExtraFlags NoExtraPeers NoExtraAPI NoExtraChurnArgs NoExtraCounters
53+
NoExtraState NoExtraDebugState NoExtraFlags NoExtraPeers
54+
NoExtraAPI NoExtraChurnArgs NoExtraCounters NoExtraTracer
5455
IOException
5556
Resolver
5657
m

dmq-node/src/DMQ/Tracer.hs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ module DMQ.Tracer
1919
, NoExtraConfig (..)
2020
, NoExtraAPI (..)
2121
, NoExtraChurnArgs (..)
22+
, NoExtraTracer (..)
2223
) where
2324

2425
import Codec.CBOR.Term (Term)
@@ -103,6 +104,10 @@ instance ToJSON NoExtraDebugState where
103104
omitField _ = True
104105
data NoExtraChurnArgs = NoExtraChurnArgs
105106
data NoExtraAPI = NoExtraAPI
107+
data NoExtraTracer = NoExtraTracer
108+
instance ToJSON NoExtraTracer where
109+
toJSON _ = Null
110+
omitField _ = True
106111

107112
instance ToJSON (Governor.PeerSelectionCounters NoExtraCounters) where
108113
toJSON Governor.PeerSelectionCounters {..} =
@@ -164,6 +169,7 @@ dmqDiffusionTracers
164169
NoExtraFlags
165170
NoExtraPeers
166171
NoExtraCounters
172+
NoExtraTracer
167173
m
168174
dmqDiffusionTracers
169175
Configuration {

0 commit comments

Comments
 (0)