@@ -18,6 +18,8 @@ import (
1818 "github.com/lightninglabs/taproot-assets/tapchannel"
1919 "github.com/lightninglabs/taproot-assets/taprpc"
2020 "github.com/lightninglabs/taproot-assets/taprpc/mintrpc"
21+ oraclerpc "github.com/lightninglabs/taproot-assets/taprpc/priceoraclerpc"
22+ "github.com/lightninglabs/taproot-assets/taprpc/rfqrpc"
2123 tchrpc "github.com/lightninglabs/taproot-assets/taprpc/tapchannelrpc"
2224 "github.com/lightninglabs/taproot-assets/taprpc/universerpc"
2325 "github.com/lightninglabs/taproot-assets/tapscript"
4850 shortTimeout = time .Second * 5
4951
5052 defaultPaymentStatus = fn .None [lnrpc.Payment_PaymentStatus ]()
53+
54+ // nolint: lll
55+ errNoBalance = lnrpc .PaymentFailureReason_FAILURE_REASON_INSUFFICIENT_BALANCE
56+ errNoRoute = lnrpc .PaymentFailureReason_FAILURE_REASON_NO_ROUTE
5157)
5258
5359var (
@@ -528,6 +534,7 @@ func testCustomChannels(_ context.Context, net *NetworkHarness,
528534 )
529535 payInvoiceWithSatoshi (
530536 t .t , charlie , invoiceResp , lnrpc .Payment_FAILED ,
537+ fn .None [lnrpc.PaymentFailureReason ](),
531538 )
532539 logBalance (t .t , nodes , assetID , "after asset invoice paid with sats" )
533540
@@ -574,7 +581,10 @@ func testCustomChannels(_ context.Context, net *NetworkHarness,
574581 invoiceResp = createAssetInvoice (
575582 t .t , erin , fabia , fabiaInvoiceAssetAmount2 , assetID ,
576583 )
577- payInvoiceWithSatoshi (t .t , dave , invoiceResp , lnrpc .Payment_SUCCEEDED )
584+ payInvoiceWithSatoshi (
585+ t .t , dave , invoiceResp , lnrpc .Payment_SUCCEEDED ,
586+ fn .None [lnrpc.PaymentFailureReason ](),
587+ )
578588 logBalance (t .t , nodes , assetID , "after invoice" )
579589
580590 erinAssetBalance -= fabiaInvoiceAssetAmount2
@@ -1006,7 +1016,10 @@ func testCustomChannelsGroupedAsset(_ context.Context, net *NetworkHarness,
10061016 invoiceResp = createAssetInvoice (
10071017 t .t , erin , fabia , fabiaInvoiceAssetAmount2 , assetID ,
10081018 )
1009- payInvoiceWithSatoshi (t .t , dave , invoiceResp , lnrpc .Payment_SUCCEEDED )
1019+ payInvoiceWithSatoshi (
1020+ t .t , dave , invoiceResp , lnrpc .Payment_SUCCEEDED ,
1021+ fn .None [lnrpc.PaymentFailureReason ](),
1022+ )
10101023 logBalance (t .t , nodes , assetID , "after invoice" )
10111024
10121025 erinAssetBalance -= fabiaInvoiceAssetAmount2
@@ -2015,7 +2028,10 @@ func testCustomChannelsLiquidityEdgeCases(_ context.Context,
20152028 // channels, where the total asset value is less than the default anchor
20162029 // amount of 354 sats.
20172030 invoiceResp = createAssetInvoice (t .t , dave , charlie , 1 , assetID )
2018- payInvoiceWithSatoshi (t .t , yara , invoiceResp , lnrpc .Payment_FAILED )
2031+ payInvoiceWithSatoshi (
2032+ t .t , yara , invoiceResp , lnrpc .Payment_FAILED ,
2033+ fn .Some (lnrpc .PaymentFailureReason_FAILURE_REASON_NO_ROUTE ),
2034+ )
20192035
20202036 logBalance (t .t , nodes , assetID , "after small payment (asset " +
20212037 "invoice, <354sats)" )
@@ -2686,7 +2702,7 @@ func testCustomChannelsOraclePricing(_ context.Context,
26862702 )
26872703}
26882704
2689- // testCustomChannelsFee tests the whether the custom channel funding process
2705+ // testCustomChannelsFee tests whether the custom channel funding process
26902706// fails if the proposed fee rate is lower than the minimum relay fee.
26912707func testCustomChannelsFee (_ context.Context ,
26922708 net * NetworkHarness , t * harnessTest ) {
0 commit comments