mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-09-05 17:05:50 +02:00
lnwire: add timestamps to ReplyChannelRange msg
This commit is contained in:
@@ -1159,12 +1159,25 @@ func TestLightningWireProtocol(t *testing.T) {
|
||||
req.EncodingType = EncodingSortedPlain
|
||||
}
|
||||
|
||||
numChanIDs := rand.Int31n(5000)
|
||||
numChanIDs := rand.Int31n(4000)
|
||||
for i := int32(0); i < numChanIDs; i++ {
|
||||
req.ShortChanIDs = append(req.ShortChanIDs,
|
||||
NewShortChanIDFromInt(uint64(r.Int63())))
|
||||
}
|
||||
|
||||
// With a 50/50 chance, add some timestamps.
|
||||
if r.Int31()%2 == 0 {
|
||||
for i := int32(0); i < numChanIDs; i++ {
|
||||
timestamps := ChanUpdateTimestamps{
|
||||
Timestamp1: rand.Uint32(),
|
||||
Timestamp2: rand.Uint32(),
|
||||
}
|
||||
req.Timestamps = append(
|
||||
req.Timestamps, timestamps,
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
v[0] = reflect.ValueOf(req)
|
||||
},
|
||||
MsgQueryChannelRange: func(v []reflect.Value, r *rand.Rand) {
|
||||
|
Reference in New Issue
Block a user