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
|
// Construct the response we expect after sending a duplicate packet
|
||||||
// that fails due to sphinx replay detection.
|
// that fails due to sphinx replay detection.
|
||||||
replayErr := fmt.Sprintf("unable to route payment to destination: "+
|
replayErr := "TemporaryChannelFailure"
|
||||||
"TemporaryChannelFailure: unable to de-obfuscate onion failure, "+
|
if !strings.Contains(resp.PaymentError, replayErr) {
|
||||||
"htlc with hash(%x): unable to retrieve onion failure",
|
t.Fatalf("received payment error: %v, expected %v",
|
||||||
invoiceResp.RHash)
|
resp.PaymentError, replayErr)
|
||||||
|
|
||||||
if resp.PaymentError != replayErr {
|
|
||||||
t.Fatalf("received payment error: %v", resp.PaymentError)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Since the payment failed, the balance should still be left
|
// Since the payment failed, the balance should still be left
|
||||||
|
Loading…
Reference in New Issue
Block a user