@@ -322,8 +322,8 @@ def run_test(self):
322
322
#compare fee of a standard pubkeyhash transaction
323
323
inputs = []
324
324
outputs = {self .nodes [1 ].getnewaddress ():1.1 }
325
- rawTx = self .nodes [0 ].createrawtransaction (inputs , outputs )
326
- fundedTx = self .nodes [0 ].fundrawtransaction (rawTx )
325
+ rawtx = self .nodes [0 ].createrawtransaction (inputs , outputs )
326
+ fundedTx = self .nodes [0 ].fundrawtransaction (rawtx )
327
327
328
328
#create same transaction over sendtoaddress
329
329
txId = self .nodes [0 ].sendtoaddress (self .nodes [1 ].getnewaddress (), 1.1 )
@@ -338,8 +338,8 @@ def run_test(self):
338
338
#compare fee of a standard pubkeyhash transaction with multiple outputs
339
339
inputs = []
340
340
outputs = {self .nodes [1 ].getnewaddress ():1.1 ,self .nodes [1 ].getnewaddress ():1.2 ,self .nodes [1 ].getnewaddress ():0.1 ,self .nodes [1 ].getnewaddress ():1.3 ,self .nodes [1 ].getnewaddress ():0.2 ,self .nodes [1 ].getnewaddress ():0.3 }
341
- rawTx = self .nodes [0 ].createrawtransaction (inputs , outputs )
342
- fundedTx = self .nodes [0 ].fundrawtransaction (rawTx )
341
+ rawtx = self .nodes [0 ].createrawtransaction (inputs , outputs )
342
+ fundedTx = self .nodes [0 ].fundrawtransaction (rawtx )
343
343
#create same transaction over sendtoaddress
344
344
txId = self .nodes [0 ].sendmany ("" , outputs )
345
345
signedFee = self .nodes [0 ].getrawmempool (True )[txId ]['fee' ]
@@ -364,8 +364,8 @@ def run_test(self):
364
364
365
365
inputs = []
366
366
outputs = {mSigObj :1.1 }
367
- rawTx = self .nodes [0 ].createrawtransaction (inputs , outputs )
368
- fundedTx = self .nodes [0 ].fundrawtransaction (rawTx )
367
+ rawtx = self .nodes [0 ].createrawtransaction (inputs , outputs )
368
+ fundedTx = self .nodes [0 ].fundrawtransaction (rawtx )
369
369
370
370
#create same transaction over sendtoaddress
371
371
txId = self .nodes [0 ].sendtoaddress (mSigObj , 1.1 )
@@ -397,8 +397,8 @@ def run_test(self):
397
397
398
398
inputs = []
399
399
outputs = {mSigObj :1.1 }
400
- rawTx = self .nodes [0 ].createrawtransaction (inputs , outputs )
401
- fundedTx = self .nodes [0 ].fundrawtransaction (rawTx )
400
+ rawtx = self .nodes [0 ].createrawtransaction (inputs , outputs )
401
+ fundedTx = self .nodes [0 ].fundrawtransaction (rawtx )
402
402
403
403
#create same transaction over sendtoaddress
404
404
txId = self .nodes [0 ].sendtoaddress (mSigObj , 1.1 )
@@ -432,8 +432,8 @@ def run_test(self):
432
432
oldBalance = self .nodes [1 ].getbalance ()
433
433
inputs = []
434
434
outputs = {self .nodes [1 ].getnewaddress ():1.1 }
435
- rawTx = self .nodes [2 ].createrawtransaction (inputs , outputs )
436
- fundedTx = self .nodes [2 ].fundrawtransaction (rawTx )
435
+ rawtx = self .nodes [2 ].createrawtransaction (inputs , outputs )
436
+ fundedTx = self .nodes [2 ].fundrawtransaction (rawtx )
437
437
438
438
signedTx = self .nodes [2 ].signrawtransaction (fundedTx ['hex' ])
439
439
txId = self .nodes [2 ].sendrawtransaction (signedTx ['hex' ])
@@ -469,10 +469,10 @@ def run_test(self):
469
469
self .nodes [1 ].getnewaddress ()
470
470
inputs = []
471
471
outputs = {self .nodes [0 ].getnewaddress ():1.1 }
472
- rawTx = self .nodes [1 ].createrawtransaction (inputs , outputs )
472
+ rawtx = self .nodes [1 ].createrawtransaction (inputs , outputs )
473
473
# fund a transaction that requires a new key for the change output
474
474
# creating the key must be impossible because the wallet is locked
475
- assert_raises_jsonrpc (- 4 , "Keypool ran out, please call keypoolrefill first" , self .nodes [1 ].fundrawtransaction , rawTx )
475
+ assert_raises_jsonrpc (- 4 , "Keypool ran out, please call keypoolrefill first" , self .nodes [1 ].fundrawtransaction , rawtx )
476
476
477
477
#refill the keypool
478
478
self .nodes [1 ].walletpassphrase ("test" , 100 )
@@ -484,8 +484,8 @@ def run_test(self):
484
484
485
485
inputs = []
486
486
outputs = {self .nodes [0 ].getnewaddress ():1.1 }
487
- rawTx = self .nodes [1 ].createrawtransaction (inputs , outputs )
488
- fundedTx = self .nodes [1 ].fundrawtransaction (rawTx )
487
+ rawtx = self .nodes [1 ].createrawtransaction (inputs , outputs )
488
+ fundedTx = self .nodes [1 ].fundrawtransaction (rawtx )
489
489
490
490
#now we need to unlock
491
491
self .nodes [1 ].walletpassphrase ("test" , 600 )
@@ -516,8 +516,8 @@ def run_test(self):
516
516
#fund a tx with ~20 small inputs
517
517
inputs = []
518
518
outputs = {self .nodes [0 ].getnewaddress ():0.15 ,self .nodes [0 ].getnewaddress ():0.04 }
519
- rawTx = self .nodes [1 ].createrawtransaction (inputs , outputs )
520
- fundedTx = self .nodes [1 ].fundrawtransaction (rawTx )
519
+ rawtx = self .nodes [1 ].createrawtransaction (inputs , outputs )
520
+ fundedTx = self .nodes [1 ].fundrawtransaction (rawtx )
521
521
522
522
#create same transaction over sendtoaddress
523
523
txId = self .nodes [1 ].sendmany ("" , outputs )
@@ -548,8 +548,8 @@ def run_test(self):
548
548
549
549
inputs = []
550
550
outputs = {self .nodes [0 ].getnewaddress ():0.15 ,self .nodes [0 ].getnewaddress ():0.04 }
551
- rawTx = self .nodes [1 ].createrawtransaction (inputs , outputs )
552
- fundedTx = self .nodes [1 ].fundrawtransaction (rawTx )
551
+ rawtx = self .nodes [1 ].createrawtransaction (inputs , outputs )
552
+ fundedTx = self .nodes [1 ].fundrawtransaction (rawtx )
553
553
fundedAndSignedTx = self .nodes [1 ].signrawtransaction (fundedTx ['hex' ])
554
554
txId = self .nodes [1 ].sendrawtransaction (fundedAndSignedTx ['hex' ])
555
555
self .sync_all ()
0 commit comments