rpc: various fixups for dumptxoutset

- Actually generate an assumeutxo hash and display it
- Add nchaintx to output (necessary for use in chainparams entry)
- Add path of serialized UTXO file to output
This commit is contained in:
James O'Beirne authored and James O'Beirne committed 2021-11-30 11:19:26 -05:00
1 parent ab25ef8c7f
commit ffd09281fe
4 files changed
+35 -6

No files matched your search

+4
View File
@@ -45,6 +45,10 @@ class DumptxoutsetTest(BitcoinTestFramework):
assert_equal(
digest, '7ae82c986fa5445678d2a21453bb1c86d39e47af13da137640c2b1cf8093691c')
assert_equal(
out['txoutset_hash'], 'd4b614f476b99a6e569973bf1c0120d88b1a168076f8ce25691fb41dd1cef149')
assert_equal(out['nchaintx'], 101)
# Specifying a path to an existing file will fail.
assert_raises_rpc_error(
-8, '{} already exists'.format(FILENAME), node.dumptxoutset, FILENAME)