itest: account for capped anchor commit fee rate in balance calc
This commit is contained in:
parent
99bbd992d2
commit
413ece2ccc
@ -1166,8 +1166,12 @@ func (c commitType) calcStaticFee(numHTLCs int) btcutil.Amount {
|
|||||||
|
|
||||||
// The anchor commitment type is slightly heavier, and we must also add
|
// The anchor commitment type is slightly heavier, and we must also add
|
||||||
// the value of the two anchors to the resulting fee the initiator
|
// the value of the two anchors to the resulting fee the initiator
|
||||||
// pays.
|
// pays. In addition the fee rate is capped at 10 sat/vbyte for anchor
|
||||||
|
// channels.
|
||||||
if c == commitTypeAnchors {
|
if c == commitTypeAnchors {
|
||||||
|
feePerKw = chainfee.SatPerKVByte(
|
||||||
|
lnwallet.DefaultAnchorsCommitMaxFeeRateSatPerVByte * 1000,
|
||||||
|
).FeePerKWeight()
|
||||||
commitWeight = input.AnchorCommitWeight
|
commitWeight = input.AnchorCommitWeight
|
||||||
anchors = 2 * anchorSize
|
anchors = 2 * anchorSize
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user