diff options
author | MarcoFalke <falke.marco@gmail.com> | 2016-01-04 13:54:23 +0100 |
---|---|---|
committer | MarcoFalke <falke.marco@gmail.com> | 2016-03-14 16:45:04 +0100 |
commit | fa8cd46f39778925eaf2caf812cccd9fb8503368 (patch) | |
tree | 68084803ac7bc2da9317b68b0aba11556315d5a1 /qa/rpc-tests/test_framework | |
parent | fad7dc8a6c0ca9c067a249cf8896dd2e64703e48 (diff) |
[qa] Move create_tx() to util.py
Diffstat (limited to 'qa/rpc-tests/test_framework')
-rw-r--r-- | qa/rpc-tests/test_framework/util.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/qa/rpc-tests/test_framework/util.py b/qa/rpc-tests/test_framework/util.py index 8c472a518d..ce3102988a 100644 --- a/qa/rpc-tests/test_framework/util.py +++ b/qa/rpc-tests/test_framework/util.py @@ -493,6 +493,14 @@ def gen_return_txouts(): txouts = txouts + script_pubkey return txouts +def create_tx(node, coinbase, to_address, amount): + inputs = [{ "txid" : coinbase, "vout" : 0}] + outputs = { to_address : amount } + rawtx = node.createrawtransaction(inputs, outputs) + signresult = node.signrawtransaction(rawtx) + assert_equal(signresult["complete"], True) + return signresult["hex"] + def create_lots_of_big_transactions(node, txouts, utxos, fee): addr = node.getnewaddress() txids = [] |