From 85a2d4640f0b9a431da7bd686a337b88d7ffa324 Mon Sep 17 00:00:00 2001 From: Conner Fromknecht Date: Wed, 5 Sep 2018 20:51:59 -0700 Subject: [PATCH] lnwire/lnwire_test: assert nil 0-length sid reply msg --- lnwire/lnwire_test.go | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/lnwire/lnwire_test.go b/lnwire/lnwire_test.go index b30184bc..40907064 100644 --- a/lnwire/lnwire_test.go +++ b/lnwire/lnwire_test.go @@ -711,7 +711,6 @@ func TestLightningWireProtocol(t *testing.T) { } numChanIDs := rand.Int31n(5000) - for i := int32(0); i < numChanIDs; i++ { req.ShortChanIDs = append(req.ShortChanIDs, NewShortChanIDFromInt(uint64(r.Int63()))) @@ -743,12 +742,9 @@ func TestLightningWireProtocol(t *testing.T) { } numChanIDs := rand.Int31n(5000) - - req.ShortChanIDs = make([]ShortChannelID, numChanIDs) for i := int32(0); i < numChanIDs; i++ { - req.ShortChanIDs[i] = NewShortChanIDFromInt( - uint64(r.Int63()), - ) + req.ShortChanIDs = append(req.ShortChanIDs, + NewShortChanIDFromInt(uint64(r.Int63()))) } v[0] = reflect.ValueOf(req)