test: update itest to no longer expect incorrect message for sphinx replay test
In this commit, we update the itests to expect the correct message for the sphinx replay test. Before the fixes in the prior commits, we expected the wrong error since we were actually unable to decrypt these converted malformed HTLC errors. Now, we'll properly return a parse able error, so we assert against that error instead of the failure to decode an error.
This commit is contained in:
parent
56c969c911
commit
2f2a907b58
11
lnd_test.go
11
lnd_test.go
@ -3522,13 +3522,10 @@ func testSphinxReplayPersistence(net *lntest.NetworkHarness, t *harnessTest) {
|
||||
|
||||
// Construct the response we expect after sending a duplicate packet
|
||||
// that fails due to sphinx replay detection.
|
||||
replayErr := fmt.Sprintf("unable to route payment to destination: "+
|
||||
"TemporaryChannelFailure: unable to de-obfuscate onion failure, "+
|
||||
"htlc with hash(%x): unable to retrieve onion failure",
|
||||
invoiceResp.RHash)
|
||||
|
||||
if resp.PaymentError != replayErr {
|
||||
t.Fatalf("received payment error: %v", resp.PaymentError)
|
||||
replayErr := "TemporaryChannelFailure"
|
||||
if !strings.Contains(resp.PaymentError, replayErr) {
|
||||
t.Fatalf("received payment error: %v, expected %v",
|
||||
resp.PaymentError, replayErr)
|
||||
}
|
||||
|
||||
// Since the payment failed, the balance should still be left
|
||||
|
Loading…
Reference in New Issue
Block a user