mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-19 13:27:35 +02:00
test: Test empty array in gettxoutproof
This commit is contained in:
parent
fa56e866e8
commit
faf5eb45c4
1 changed files with 2 additions and 0 deletions
|
|
@ -77,6 +77,8 @@ class MerkleBlockTest(BitcoinTestFramework):
|
||||||
assert_equal(self.nodes[0].verifytxoutproof(self.nodes[1].gettxoutproof([txid_spent])), [txid_spent])
|
assert_equal(self.nodes[0].verifytxoutproof(self.nodes[1].gettxoutproof([txid_spent])), [txid_spent])
|
||||||
# We can't get a proof if we specify transactions from different blocks
|
# We can't get a proof if we specify transactions from different blocks
|
||||||
assert_raises_rpc_error(-5, "Not all transactions found in specified or retrieved block", self.nodes[0].gettxoutproof, [txid1, txid3])
|
assert_raises_rpc_error(-5, "Not all transactions found in specified or retrieved block", self.nodes[0].gettxoutproof, [txid1, txid3])
|
||||||
|
# Test empty list
|
||||||
|
assert_raises_rpc_error(-5, "Transaction not yet in block", self.nodes[0].gettxoutproof, [])
|
||||||
|
|
||||||
# Now we'll try tweaking a proof.
|
# Now we'll try tweaking a proof.
|
||||||
proof = self.nodes[1].gettxoutproof([txid1, txid2])
|
proof = self.nodes[1].gettxoutproof([txid1, txid2])
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue