multi: fix issues reported by whitespace linter

This commit is contained in:
Oliver Gugger
2022-02-15 16:25:54 +01:00
parent 8d83778314
commit 13f187046b
14 changed files with 26 additions and 18 deletions

View File

@@ -614,8 +614,8 @@ func createTestGraphFromChannels(useCache bool, testChannels []*testChannel,
for _, testChannel := range testChannels {
for _, node := range []*testChannelEnd{
testChannel.Node1, testChannel.Node2} {
testChannel.Node1, testChannel.Node2,
} {
_, exists := aliasMap[node.Alias]
if !exists {
var features *lnwire.FeatureVector

View File

@@ -779,7 +779,6 @@ func (p *shardHandler) handleSendError(attempt *channeldb.HTLCAttemptInfo,
if err := p.router.cfg.Control.Fail(
p.identifier, *reason,
); err != nil {
log.Errorf("unable to report failure to control "+
"tower: %v", err)

View File

@@ -670,7 +670,6 @@ func TestSendPaymentErrorFeeInsufficientPrivateEdge(t *testing.T) {
copy(preImage[:], bytes.Repeat([]byte{9}, 32))
ctx.router.cfg.Payer.(*mockPaymentAttemptDispatcherOld).setPaymentResult(
func(firstHop lnwire.ShortChannelID) ([32]byte, error) {
if firstHop != roasbeefSongoku || errorReturned {
return preImage, nil
}
@@ -685,7 +684,8 @@ func TestSendPaymentErrorFeeInsufficientPrivateEdge(t *testing.T) {
Update: errChanUpdate,
}, 1,
)
})
},
)
// Send off the payment request to the router, route through son
// goku and then across the private channel to elst.
@@ -802,7 +802,6 @@ func TestSendPaymentPrivateEdgeUpdateFeeExceedsLimit(t *testing.T) {
copy(preImage[:], bytes.Repeat([]byte{9}, 32))
ctx.router.cfg.Payer.(*mockPaymentAttemptDispatcherOld).setPaymentResult(
func(firstHop lnwire.ShortChannelID) ([32]byte, error) {
if firstHop != roasbeefSongoku || errorReturned {
return preImage, nil
}
@@ -817,7 +816,8 @@ func TestSendPaymentPrivateEdgeUpdateFeeExceedsLimit(t *testing.T) {
Update: errChanUpdate,
}, 1,
)
})
},
)
// Send off the payment request to the router, route through son
// goku and then across the private channel to elst.
@@ -3071,7 +3071,6 @@ func TestSendToRouteMultiShardSend(t *testing.T) {
ctx.router.cfg.Payer.(*mockPaymentAttemptDispatcherOld).setPaymentResult(
func(firstHop lnwire.ShortChannelID) ([32]byte, error) {
// Signal that the shard has been initiated and is
// waiting for a result.
waitForResultSignal <- struct{}{}
@@ -3082,7 +3081,8 @@ func TestSendToRouteMultiShardSend(t *testing.T) {
return [32]byte{}, fmt.Errorf("failure")
}
return res, nil
})
},
)
// Launch three shards by calling SendToRoute in three goroutines,
// returning their final error on the channel.