@@ -73,11 +73,13 @@ var (
73
73
OutgoingChanSet : loopdb.ChannelSet {chanID1 .ToUint64 ()},
74
74
MaxPrepayRoutingFee : prepayFee ,
75
75
MaxSwapRoutingFee : routingFee ,
76
- MaxMinerFee : scaleMinerFee (testQuote .MinerFee ),
77
- MaxSwapFee : testQuote .SwapFee ,
78
- MaxPrepayAmount : testQuote .PrepayAmount ,
79
- SweepConfTarget : defaultConfTarget ,
80
- Initiator : autoloopSwapInitiator ,
76
+ MaxMinerFee : scaleMaxMinerFee (
77
+ scaleMinerFee (testQuote .MinerFee ),
78
+ ),
79
+ MaxSwapFee : testQuote .SwapFee ,
80
+ MaxPrepayAmount : testQuote .PrepayAmount ,
81
+ SweepConfTarget : defaultConfTarget ,
82
+ Initiator : autoloopSwapInitiator ,
81
83
}
82
84
83
85
// chan2Rec is the suggested swap for channel 2 when we use chanRule.
@@ -86,11 +88,13 @@ var (
86
88
OutgoingChanSet : loopdb.ChannelSet {chanID2 .ToUint64 ()},
87
89
MaxPrepayRoutingFee : prepayFee ,
88
90
MaxSwapRoutingFee : routingFee ,
89
- MaxMinerFee : scaleMinerFee (testQuote .MinerFee ),
90
- MaxPrepayAmount : testQuote .PrepayAmount ,
91
- MaxSwapFee : testQuote .SwapFee ,
92
- SweepConfTarget : defaultConfTarget ,
93
- Initiator : autoloopSwapInitiator ,
91
+ MaxMinerFee : scaleMaxMinerFee (
92
+ scaleMinerFee (testQuote .MinerFee ),
93
+ ),
94
+ MaxPrepayAmount : testQuote .PrepayAmount ,
95
+ MaxSwapFee : testQuote .SwapFee ,
96
+ SweepConfTarget : defaultConfTarget ,
97
+ Initiator : autoloopSwapInitiator ,
94
98
}
95
99
96
100
// chan1Out is a contract that uses channel 1, used to represent on
@@ -771,11 +775,13 @@ func TestSuggestSwaps(t *testing.T) {
771
775
},
772
776
MaxPrepayRoutingFee : prepay ,
773
777
MaxSwapRoutingFee : routing ,
774
- MaxMinerFee : scaleMinerFee (testQuote .MinerFee ),
775
- MaxSwapFee : testQuote .SwapFee ,
776
- MaxPrepayAmount : testQuote .PrepayAmount ,
777
- SweepConfTarget : defaultConfTarget ,
778
- Initiator : autoloopSwapInitiator ,
778
+ MaxMinerFee : scaleMaxMinerFee (
779
+ scaleMinerFee (testQuote .MinerFee ),
780
+ ),
781
+ MaxSwapFee : testQuote .SwapFee ,
782
+ MaxPrepayAmount : testQuote .PrepayAmount ,
783
+ SweepConfTarget : defaultConfTarget ,
784
+ Initiator : autoloopSwapInitiator ,
779
785
},
780
786
},
781
787
DisqualifiedChans : noneDisqualified ,
@@ -1330,11 +1336,13 @@ func TestSizeRestrictions(t *testing.T) {
1330
1336
OutgoingChanSet : loopdb.ChannelSet {chanID1 .ToUint64 ()},
1331
1337
MaxPrepayRoutingFee : prepay ,
1332
1338
MaxSwapRoutingFee : routing ,
1333
- MaxMinerFee : scaleMinerFee (testQuote .MinerFee ),
1334
- MaxSwapFee : testQuote .SwapFee ,
1335
- MaxPrepayAmount : testQuote .PrepayAmount ,
1336
- SweepConfTarget : defaultConfTarget ,
1337
- Initiator : autoloopSwapInitiator ,
1339
+ MaxMinerFee : scaleMaxMinerFee (
1340
+ scaleMinerFee (testQuote .MinerFee ),
1341
+ ),
1342
+ MaxSwapFee : testQuote .SwapFee ,
1343
+ MaxPrepayAmount : testQuote .PrepayAmount ,
1344
+ SweepConfTarget : defaultConfTarget ,
1345
+ Initiator : autoloopSwapInitiator ,
1338
1346
}
1339
1347
)
1340
1348
@@ -1487,7 +1495,9 @@ func TestFeePercentage(t *testing.T) {
1487
1495
rec = loop.OutRequest {
1488
1496
Amount : 7500 ,
1489
1497
OutgoingChanSet : loopdb.ChannelSet {chanID1 .ToUint64 ()},
1490
- MaxMinerFee : scaleMinerFee (okQuote .MinerFee ),
1498
+ MaxMinerFee : scaleMaxMinerFee (
1499
+ scaleMinerFee (testQuote .MinerFee ),
1500
+ ),
1491
1501
MaxSwapFee : okQuote .SwapFee ,
1492
1502
MaxPrepayAmount : okQuote .PrepayAmount ,
1493
1503
SweepConfTarget : defaultConfTarget ,
@@ -1555,7 +1565,7 @@ func TestFeePercentage(t *testing.T) {
1555
1565
quote : & loop.LoopOutQuote {
1556
1566
SwapFee : 60 ,
1557
1567
PrepayAmount : 30 ,
1558
- MinerFee : 1 ,
1568
+ MinerFee : 50 ,
1559
1569
},
1560
1570
suggestions : & Suggestions {
1561
1571
DisqualifiedChans : map [lnwire.ShortChannelID ]Reason {
@@ -1650,7 +1660,9 @@ func TestBudgetWithLoopin(t *testing.T) {
1650
1660
rec = loop.OutRequest {
1651
1661
Amount : 7500 ,
1652
1662
OutgoingChanSet : loopdb.ChannelSet {chanID1 .ToUint64 ()},
1653
- MaxMinerFee : scaleMinerFee (okQuote .MinerFee ),
1663
+ MaxMinerFee : scaleMaxMinerFee (
1664
+ scaleMinerFee (testQuote .MinerFee ),
1665
+ ),
1654
1666
MaxSwapFee : okQuote .SwapFee ,
1655
1667
MaxPrepayAmount : okQuote .PrepayAmount ,
1656
1668
SweepConfTarget : defaultConfTarget ,
0 commit comments