multi: rename FailUnknownPaymentHash to FailIncorrectDetails
Align naming better with the lightning spec. Not the full name of the failure (FailIncorrectOrUnknownPaymentDetails) is used, because this would cause too many long lines in the code.
This commit is contained in:
11 files changed
+219
-214
No files matched your search
@@ -1803,7 +1803,7 @@ func TestSwitchSendPayment(t *testing.T) {
|
||||
// the add htlc request with error and sent the htlc fail request
|
||||
// back. This request should be forwarded back to alice channel link.
|
||||
obfuscator := NewMockObfuscator()
|
||||
failure := lnwire.NewFailUnknownPaymentHash(update.Amount)
|
||||
failure := lnwire.NewFailIncorrectDetails(update.Amount)
|
||||
reason, err := obfuscator.EncryptFirstHop(failure)
|
||||
if err != nil {
|
||||
t.Fatalf("unable obfuscate failure: %v", err)
|
||||
@@ -1824,8 +1824,9 @@ func TestSwitchSendPayment(t *testing.T) {
|
||||
|
||||
select {
|
||||
case err := <-errChan:
|
||||
assertFailureCode(t, err, lnwire.CodeUnknownPaymentHash)
|
||||
|
||||
assertFailureCode(
|
||||
t, err, lnwire.CodeIncorrectOrUnknownPaymentDetails,
|
||||
)
|
||||
case <-time.After(time.Second):
|
||||
t.Fatal("err wasn't received")
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user