Skip to content

Commit 6657572

Browse files
committed
itest: allow public taproot chan tests
1 parent 5d02a4b commit 6657572

7 files changed

+7
-210
lines changed

itest/lnd_channel_backup_test.go

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -106,13 +106,6 @@ func newChanRestoreScenario(ht *lntest.HarnessTest, ct lnrpc.CommitmentType,
106106
// with a portion pushed.
107107
ht.ConnectNodes(dave, carol)
108108

109-
// If the commitment type is taproot, then the channel must also be
110-
// private.
111-
var privateChan bool
112-
if ct == lnrpc.CommitmentType_SIMPLE_TAPROOT {
113-
privateChan = true
114-
}
115-
116109
return &chanRestoreScenario{
117110
carol: carol,
118111
dave: dave,
@@ -123,7 +116,6 @@ func newChanRestoreScenario(ht *lntest.HarnessTest, ct lnrpc.CommitmentType,
123116
PushAmt: pushAmt,
124117
ZeroConf: zeroConf,
125118
CommitmentType: ct,
126-
Private: privateChan,
127119
},
128120
}
129121
}
@@ -648,13 +640,6 @@ func runChanRestoreScenarioCommitTypes(ht *lntest.HarnessTest,
648640
multi, err := os.ReadFile(backupFilePath)
649641
require.NoError(ht, err)
650642

651-
// If this was a zero conf taproot channel, then since it's private,
652-
// we'll need to mine an extra block (framework won't mine extra blocks
653-
// otherwise).
654-
if ct == lnrpc.CommitmentType_SIMPLE_TAPROOT && zeroConf {
655-
ht.MineBlocksAndAssertNumTxes(1, 1)
656-
}
657-
658643
// Now that we have Dave's backup file, we'll create a new nodeRestorer
659644
// that we'll restore using the on-disk channels.backup.
660645
restoredNodeFunc := chanRestoreViaRPC(

itest/lnd_channel_force_close_test.go

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -119,18 +119,8 @@ func channelForceClosureTest(ht *lntest.HarnessTest,
119119
carolBalResp := carol.RPC.WalletBalance()
120120
carolStartingBalance := carolBalResp.ConfirmedBalance
121121

122-
// If the channel is a taproot channel, then we'll need to create a
123-
// private channel.
124-
//
125-
// TODO(roasbeef): lift after G175
126-
var privateChan bool
127-
if channelType == lnrpc.CommitmentType_SIMPLE_TAPROOT {
128-
privateChan = true
129-
}
130-
131122
chanPoint := ht.OpenChannel(
132123
alice, carol, lntest.OpenChannelParams{
133-
Private: privateChan,
134124
Amt: chanAmt,
135125
PushAmt: pushAmt,
136126
CommitmentType: channelType,

itest/lnd_funding_test.go

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -61,16 +61,6 @@ func testBasicChannelFunding(ht *lntest.HarnessTest) {
6161
// connected to the funding flow can properly be executed.
6262
ht.EnsureConnected(carol, dave)
6363

64-
var privateChan bool
65-
66-
// If this is to be a taproot channel type, then it needs to be
67-
// private, otherwise it'll be rejected by Dave.
68-
//
69-
// TODO(roasbeef): lift after gossip 1.75
70-
if carolCommitType == lnrpc.CommitmentType_SIMPLE_TAPROOT {
71-
privateChan = true
72-
}
73-
7464
// If carol wants taproot, but dave wants something
7565
// else, then we'll assert that the channel negotiation
7666
// attempt fails.
@@ -82,7 +72,6 @@ func testBasicChannelFunding(ht *lntest.HarnessTest) {
8272
amt := funding.MaxBtcFundingAmount
8373
ht.OpenChannelAssertErr(
8474
carol, dave, lntest.OpenChannelParams{
85-
Private: privateChan,
8675
Amt: amt,
8776
CommitmentType: carolCommitType,
8877
}, expectedErr,
@@ -92,7 +81,7 @@ func testBasicChannelFunding(ht *lntest.HarnessTest) {
9281
}
9382

9483
carolChan, daveChan, closeChan := basicChannelFundingTest(
95-
ht, carol, dave, nil, privateChan, &carolCommitType,
84+
ht, carol, dave, nil, false, &carolCommitType,
9685
)
9786

9887
// Both nodes should report the same commitment

0 commit comments

Comments
 (0)