Skip to content

Commit 50ba669

Browse files
committed
remove unused functions
the functions `create_transaction()` and `create_raw_transaction()` were no longer used hence removed.
1 parent eec23da commit 50ba669

File tree

1 file changed

+0
-24
lines changed

1 file changed

+0
-24
lines changed

test/functional/test_framework/blocktools.py

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -162,30 +162,6 @@ def create_tx_with_script(prevtx, n, script_sig=b"", *, amount, script_pub_key=C
162162
tx.calc_sha256()
163163
return tx
164164

165-
def create_transaction(node, txid, to_address, *, amount):
166-
""" Return signed transaction spending the first output of the
167-
input txid. Note that the node must have a wallet that can
168-
sign for the output that is being spent.
169-
"""
170-
raw_tx = create_raw_transaction(node, txid, to_address, amount=amount)
171-
tx = tx_from_hex(raw_tx)
172-
return tx
173-
174-
def create_raw_transaction(node, txid, to_address, *, amount):
175-
""" Return raw signed transaction spending the first output of the
176-
input txid. Note that the node must have a wallet that can sign
177-
for the output that is being spent.
178-
"""
179-
psbt = node.createpsbt(inputs=[{"txid": txid, "vout": 0}], outputs={to_address: amount})
180-
for _ in range(2):
181-
for w in node.listwallets():
182-
wrpc = node.get_wallet_rpc(w)
183-
signed_psbt = wrpc.walletprocesspsbt(psbt)
184-
psbt = signed_psbt['psbt']
185-
final_psbt = node.finalizepsbt(psbt)
186-
assert_equal(final_psbt["complete"], True)
187-
return final_psbt['hex']
188-
189165
def get_legacy_sigopcount_block(block, accurate=True):
190166
count = 0
191167
for tx in block.vtx:

0 commit comments

Comments
 (0)