Add tests for new JoinSplit keys returned by z_listreceivedbyaddress

This commit is contained in:
Jonathan "Duke" Leto 2018-03-27 15:16:53 -07:00
parent cb7bcd21ae
commit afdd64c6ae
1 changed files with 6 additions and 0 deletions

View File

@ -89,6 +89,12 @@ class ZkeyImportExportTest (BitcoinTestFramework):
try:
assert_equal(amts, [tx["amount"] for tx in txs])
for tx in txs:
# make sure JoinSplit keys exist and have valid values
assert_equal( "jsindex" in tx, True)
assert_equal( "jsoutindex" in tx, True)
assert_greater_than( tx["jsindex"], -1 )
assert_greater_than( tx["jsoutindex"], -1 )
except AssertionError:
logging.error(
'Expected amounts: %r; txs: %r',