@@ -693,11 +693,15 @@ func TestChannelArbitratorLocalForceClose(t *testing.T) {
693693 chanArbCtx .AssertState (StateCommitmentBroadcasted )
694694
695695 // Now notify about the local force close getting confirmed.
696+ //
697+ //nolint:lll
696698 chanArb .cfg .ChainEvents .LocalUnilateralClosure <- & LocalUnilateralCloseInfo {
697699 SpendDetail : & chainntnfs.SpendDetail {},
698700 LocalForceCloseSummary : & lnwallet.LocalForceCloseSummary {
699- CloseTx : & wire.MsgTx {},
700- HtlcResolutions : & lnwallet.HtlcResolutions {},
701+ CloseTx : & wire.MsgTx {},
702+ ContractResolutions : fn .Some (lnwallet.ContractResolutions {
703+ HtlcResolutions : & lnwallet.HtlcResolutions {},
704+ }),
701705 },
702706 ChannelCloseSummary : & channeldb.ChannelCloseSummary {},
703707 }
@@ -969,15 +973,18 @@ func TestChannelArbitratorLocalForceClosePendingHtlc(t *testing.T) {
969973 },
970974 }
971975
976+ //nolint:lll
972977 chanArb .cfg .ChainEvents .LocalUnilateralClosure <- & LocalUnilateralCloseInfo {
973978 SpendDetail : & chainntnfs.SpendDetail {},
974979 LocalForceCloseSummary : & lnwallet.LocalForceCloseSummary {
975980 CloseTx : closeTx ,
976- HtlcResolutions : & lnwallet.HtlcResolutions {
977- OutgoingHTLCs : []lnwallet.OutgoingHtlcResolution {
978- outgoingRes ,
981+ ContractResolutions : fn .Some (lnwallet.ContractResolutions {
982+ HtlcResolutions : & lnwallet.HtlcResolutions {
983+ OutgoingHTLCs : []lnwallet.OutgoingHtlcResolution {
984+ outgoingRes ,
985+ },
979986 },
980- },
987+ }) ,
981988 },
982989 ChannelCloseSummary : & channeldb.ChannelCloseSummary {},
983990 CommitSet : CommitSet {
@@ -1611,12 +1618,15 @@ func TestChannelArbitratorCommitFailure(t *testing.T) {
16111618 },
16121619 {
16131620 closeType : channeldb .LocalForceClose ,
1621+ //nolint:lll
16141622 sendEvent : func (chanArb * ChannelArbitrator ) {
16151623 chanArb .cfg .ChainEvents .LocalUnilateralClosure <- & LocalUnilateralCloseInfo {
16161624 SpendDetail : & chainntnfs.SpendDetail {},
16171625 LocalForceCloseSummary : & lnwallet.LocalForceCloseSummary {
1618- CloseTx : & wire.MsgTx {},
1619- HtlcResolutions : & lnwallet.HtlcResolutions {},
1626+ CloseTx : & wire.MsgTx {},
1627+ ContractResolutions : fn .Some (lnwallet.ContractResolutions {
1628+ HtlcResolutions : & lnwallet.HtlcResolutions {},
1629+ }),
16201630 },
16211631 ChannelCloseSummary : & channeldb.ChannelCloseSummary {},
16221632 }
@@ -1944,11 +1954,15 @@ func TestChannelArbitratorDanglingCommitForceClose(t *testing.T) {
19441954 // being canalled back. Also note that there're no HTLC
19451955 // resolutions sent since we have none on our
19461956 // commitment transaction.
1957+ //
1958+ //nolint:lll
19471959 uniCloseInfo := & LocalUnilateralCloseInfo {
19481960 SpendDetail : & chainntnfs.SpendDetail {},
19491961 LocalForceCloseSummary : & lnwallet.LocalForceCloseSummary {
1950- CloseTx : closeTx ,
1951- HtlcResolutions : & lnwallet.HtlcResolutions {},
1962+ CloseTx : closeTx ,
1963+ ContractResolutions : fn .Some (lnwallet.ContractResolutions {
1964+ HtlcResolutions : & lnwallet.HtlcResolutions {},
1965+ }),
19521966 },
19531967 ChannelCloseSummary : & channeldb.ChannelCloseSummary {},
19541968 CommitSet : CommitSet {
@@ -2754,12 +2768,15 @@ func TestChannelArbitratorAnchors(t *testing.T) {
27542768 },
27552769 }
27562770
2771+ //nolint:lll
27572772 chanArb .cfg .ChainEvents .LocalUnilateralClosure <- & LocalUnilateralCloseInfo {
27582773 SpendDetail : & chainntnfs.SpendDetail {},
27592774 LocalForceCloseSummary : & lnwallet.LocalForceCloseSummary {
2760- CloseTx : closeTx ,
2761- HtlcResolutions : & lnwallet.HtlcResolutions {},
2762- AnchorResolution : anchorResolution ,
2775+ CloseTx : closeTx ,
2776+ ContractResolutions : fn .Some (lnwallet.ContractResolutions {
2777+ HtlcResolutions : & lnwallet.HtlcResolutions {},
2778+ AnchorResolution : anchorResolution ,
2779+ }),
27632780 },
27642781 ChannelCloseSummary : & channeldb.ChannelCloseSummary {},
27652782 CommitSet : CommitSet {
@@ -2993,14 +3010,10 @@ func (m *mockChannel) NewAnchorResolutions() (*lnwallet.AnchorResolutions,
29933010 return & lnwallet.AnchorResolutions {}, nil
29943011}
29953012
2996- func (m * mockChannel ) ForceCloseChan () (* lnwallet. LocalForceCloseSummary , error ) {
3013+ func (m * mockChannel ) ForceCloseChan () (* wire. MsgTx , error ) {
29973014 if m .forceCloseErr != nil {
29983015 return nil , m .forceCloseErr
29993016 }
30003017
3001- summary := & lnwallet.LocalForceCloseSummary {
3002- CloseTx : & wire.MsgTx {},
3003- HtlcResolutions : & lnwallet.HtlcResolutions {},
3004- }
3005- return summary , nil
3018+ return & wire.MsgTx {}, nil
30063019}
0 commit comments