@@ -504,7 +504,9 @@ func testCustomChannels(_ context.Context, net *NetworkHarness,
504504 invoiceResp = createAssetInvoice (
505505 t .t , charlie , dave , daveInvoiceAssetAmount , assetID ,
506506 )
507- payInvoiceWithSatoshi (t .t , charlie , invoiceResp )
507+ payInvoiceWithSatoshi (
508+ t .t , charlie , invoiceResp , lnrpc .Payment_SUCCEEDED ,
509+ )
508510 logBalance (t .t , nodes , assetID , "after asset invoice paid with sats" )
509511
510512 // We don't need to update the asset balances of Charlie and Dave here
@@ -547,7 +549,7 @@ func testCustomChannels(_ context.Context, net *NetworkHarness,
547549 invoiceResp = createAssetInvoice (
548550 t .t , erin , fabia , fabiaInvoiceAssetAmount2 , assetID ,
549551 )
550- payInvoiceWithSatoshi (t .t , dave , invoiceResp )
552+ payInvoiceWithSatoshi (t .t , dave , invoiceResp , lnrpc . Payment_SUCCEEDED )
551553 logBalance (t .t , nodes , assetID , "after invoice" )
552554
553555 erinAssetBalance -= fabiaInvoiceAssetAmount2
@@ -967,7 +969,7 @@ func testCustomChannelsGroupedAsset(_ context.Context, net *NetworkHarness,
967969 invoiceResp = createAssetInvoice (
968970 t .t , erin , fabia , fabiaInvoiceAssetAmount2 , assetID ,
969971 )
970- payInvoiceWithSatoshi (t .t , dave , invoiceResp )
972+ payInvoiceWithSatoshi (t .t , dave , invoiceResp , lnrpc . Payment_SUCCEEDED )
971973 logBalance (t .t , nodes , assetID , "after invoice" )
972974
973975 erinAssetBalance -= fabiaInvoiceAssetAmount2
@@ -1957,6 +1959,16 @@ func testCustomChannelsLiquidityEdgeCases(_ context.Context,
19571959
19581960 logBalance (t .t , nodes , assetID , "after big asset payment (asset " +
19591961 "invoice, multi-hop)" )
1962+
1963+ // Edge case: Now Charlie creates a tiny asset invoice to be paid for by
1964+ // Yara with satoshi. This is a multi-hop payment going over 2 asset
1965+ // channels, where the total asset value is less than the default anchor
1966+ // amount of 354 sats.
1967+ invoiceResp = createAssetInvoice (t .t , dave , charlie , 1 , assetID )
1968+ payInvoiceWithSatoshi (t .t , yara , invoiceResp , lnrpc .Payment_FAILED )
1969+
1970+ logBalance (t .t , nodes , assetID , "after small payment (asset " +
1971+ "invoice, <354sats)" )
19601972}
19611973
19621974// testCustomChannelsBalanceConsistency is a test that test the balance of nodes
0 commit comments