msg
is used to indicate that the transaction should be rejected. However, before this fix, even if the tx was accepted with a non-empty msg
, the test would still pass.
msg
is used to indicate that the transaction should be rejected. However, before this fix, even if the tx was accepted with a non-empty msg
, the test would still pass.
118@@ -119,6 +119,9 @@ def tx_submit(self, node, tx, msg = ""):
119 node.sendrawtransaction(bytes_to_hex_str(tx.serialize_with_witness()), True)
120 except JSONRPCException as exp:
121 assert_equal(exp.error["message"], msg)
122+ else:
123+ if (msg):
124+ assert(False)
To print the message on failure, what about something like
0assert_equal('', msg)