From 1889554e2c02e5969a9e75df971a3ec6742a3be8 Mon Sep 17 00:00:00 2001 From: Andrew Chow Date: Fri, 7 May 2021 16:29:24 -0400 Subject: [PATCH] Remove unnecessary psbt blinding test This test is for a condition that no longer matters. Prior to CA, there was only the single value blinder for a transaction that sent unconf to conf. This would necessitate setting that single blinding factor to 0, which would make the single output not actually blinded. But with CA, because each output has an additional blinding factor for the asset, this issue no longer exists. --- test/functional/rpc_psbt.py | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/test/functional/rpc_psbt.py b/test/functional/rpc_psbt.py index b11554fe91..b769c3cce9 100755 --- a/test/functional/rpc_psbt.py +++ b/test/functional/rpc_psbt.py @@ -586,22 +586,6 @@ class PSBTTest(BitcoinTestFramework): self.nodes[0].generate(1) self.sync_all() - # Now send nonconf->conf - conf_addr = self.get_address(True, 2) - psbt = self.nodes[1].createpsbt([{"txid": txid_nonconf_2, "vout": 0}], [{conf_addr: 49.998}, {"fee": 0.001}]) - psbt = self.nodes[1].walletfillpsbtdata(psbt)['psbt'] - # Currently can't blind a transaction like this, so it fails - assert_raises_rpc_error(-8, "Unable to blind transaction: Add another output to blind in order to complete the blinding.", self.nodes[1].blindpsbt, psbt, False) - # Signing without blinding should not work either. - assert_raises_rpc_error(-25, "Transaction is not yet fully blinded", self.nodes[1].walletsignpsbt, psbt) - # If we pass "ignore_blind_fail", then it succeeds in this case without blinding. - psbt = self.nodes[1].blindpsbt(psbt, True) - psbt = self.nodes[1].walletsignpsbt(psbt)['psbt'] - hex_tx = self.nodes[1].finalizepsbt(psbt)['hex'] - self.nodes[1].sendrawtransaction(hex_tx) - self.nodes[0].generate(1) - self.sync_all() - # Now send nonconf->conf (with two outputs, blinding succeeds) conf_addr_1 = self.get_address(True, 2) conf_addr_2 = self.get_address(True, 2)