mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-08-27 14:11:04 +02:00
itest: run normal FundPsbt test case in remote-signer mode
This makes sure there is no general issue with running the pay-join FundPsbt test case in a remote signer setup.
This commit is contained in:
@@ -1060,6 +1060,14 @@ func testFundPsbt(ht *lntest.HarnessTest) {
|
|||||||
alice := ht.NewNodeWithCoins("Alice", nil)
|
alice := ht.NewNodeWithCoins("Alice", nil)
|
||||||
bob := ht.NewNodeWithCoins("Bob", nil)
|
bob := ht.NewNodeWithCoins("Bob", nil)
|
||||||
|
|
||||||
|
runFundPsbt(ht, alice, bob)
|
||||||
|
}
|
||||||
|
|
||||||
|
// runFundPsbt tests the FundPsbt RPC use case where we want to fund a PSBT
|
||||||
|
// that already has an input specified. This is a pay-join scenario where Bob
|
||||||
|
// wants to send Alice some coins, but he wants to do so in a way that doesn't
|
||||||
|
// reveal the full amount he is sending.
|
||||||
|
func runFundPsbt(ht *lntest.HarnessTest, alice, bob *node.HarnessNode) {
|
||||||
// We test a pay-join between Alice and Bob. Bob wants to send Alice
|
// We test a pay-join between Alice and Bob. Bob wants to send Alice
|
||||||
// 5 million Satoshis in a non-obvious way. So Bob selects a UTXO that's
|
// 5 million Satoshis in a non-obvious way. So Bob selects a UTXO that's
|
||||||
// bigger than 5 million Satoshis and expects the change minus the send
|
// bigger than 5 million Satoshis and expects the change minus the send
|
||||||
|
@@ -328,6 +328,11 @@ func testRemoteSignerPSBT(ht *lntest.HarnessTest) {
|
|||||||
// that aren't in the wallet. But we also want to make
|
// that aren't in the wallet. But we also want to make
|
||||||
// sure we can fund and then sign PSBTs from our wallet.
|
// sure we can fund and then sign PSBTs from our wallet.
|
||||||
runFundAndSignPsbt(ht, wo)
|
runFundAndSignPsbt(ht, wo)
|
||||||
|
|
||||||
|
// We also have a more specific funding test that does
|
||||||
|
// a pay-join payment with Carol.
|
||||||
|
ht.FundCoins(btcutil.SatoshiPerBitcoin, carol)
|
||||||
|
runFundPsbt(ht, wo, carol)
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user