@@ -169,7 +169,7 @@ def witness_script_test(self):
169
169
assert 'complete' in spending_tx_signed
170
170
assert_equal (spending_tx_signed ['complete' ], True )
171
171
172
- # Now try with a P2PKH script as the witnessScript
172
+ self . log . info ( 'Try with a P2PKH script as the witnessScript' )
173
173
embedded_addr_info = self .nodes [1 ].getaddressinfo (self .nodes [1 ].getnewaddress ('' , 'legacy' ))
174
174
embedded_privkey = self .nodes [1 ].dumpprivkey (embedded_addr_info ['address' ])
175
175
witness_script = embedded_addr_info ['scriptPubKey' ]
@@ -186,9 +186,9 @@ def witness_script_test(self):
186
186
# Check the signing completed successfully
187
187
assert 'complete' in spending_tx_signed
188
188
assert_equal (spending_tx_signed ['complete' ], True )
189
- self .nodes [1 ].sendrawtransaction (spending_tx_signed ['hex' ])
189
+ self .nodes [0 ].sendrawtransaction (spending_tx_signed ['hex' ])
190
190
191
- # Now try with a P2PK script as the witnessScript
191
+ self . log . info ( 'Try with a P2PK script as the witnessScript' )
192
192
embedded_addr_info = self .nodes [1 ].getaddressinfo (self .nodes [1 ].getnewaddress ('' , 'legacy' ))
193
193
embedded_privkey = self .nodes [1 ].dumpprivkey (embedded_addr_info ['address' ])
194
194
witness_script = CScript ([hex_str_to_bytes (embedded_addr_info ['pubkey' ]), OP_CHECKSIG ]).hex ()
@@ -205,7 +205,7 @@ def witness_script_test(self):
205
205
# Check the signing completed successfully
206
206
assert 'complete' in spending_tx_signed
207
207
assert_equal (spending_tx_signed ['complete' ], True )
208
- self .nodes [1 ].sendrawtransaction (spending_tx_signed ['hex' ])
208
+ self .nodes [0 ].sendrawtransaction (spending_tx_signed ['hex' ])
209
209
210
210
def run_test (self ):
211
211
self .successful_signing_test ()
0 commit comments