aboutsummaryrefslogtreecommitdiff
path: root/test/functional/wallet_listreceivedby.py
diff options
context:
space:
mode:
authorMarcoFalke <falke.marco@gmail.com>2018-09-10 16:58:15 -0400
committerMarcoFalke <falke.marco@gmail.com>2018-09-10 17:51:46 -0400
commitfaa669cbcd1fc799517b523b0f850e01b11bf40a (patch)
tree69dd6e0a1a1eee171b5a78a3ba465625e60f5976 /test/functional/wallet_listreceivedby.py
parent4799b0932a10c5a48706700a07899b33ef9c8bae (diff)
qa: Premine to deterministic address with -disablewallet
Diffstat (limited to 'test/functional/wallet_listreceivedby.py')
-rwxr-xr-xtest/functional/wallet_listreceivedby.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/test/functional/wallet_listreceivedby.py b/test/functional/wallet_listreceivedby.py
index 09a7c72347..554cd61daa 100755
--- a/test/functional/wallet_listreceivedby.py
+++ b/test/functional/wallet_listreceivedby.py
@@ -18,6 +18,11 @@ class ReceivedByTest(BitcoinTestFramework):
def set_test_params(self):
self.num_nodes = 2
+ def import_deterministic_coinbase_privkeys(self):
+ assert_equal(0, len(self.nodes[1].listreceivedbyaddress(minconf=0, include_empty=True, include_watchonly=True)))
+ super().import_deterministic_coinbase_privkeys()
+ self.num_cb_reward_addresses = len(self.nodes[1].listreceivedbyaddress(minconf=0, include_empty=True, include_watchonly=True))
+
def run_test(self):
# Generate block to get out of IBD
self.nodes[0].generate(1)
@@ -64,7 +69,7 @@ class ReceivedByTest(BitcoinTestFramework):
assert_raises_rpc_error(-4, "address_filter parameter was invalid", self.nodes[1].listreceivedbyaddress, minconf=0, include_empty=True, include_watchonly=True, address_filter="bamboozling")
# Another address receive money
res = self.nodes[1].listreceivedbyaddress(0, True, True)
- assert_equal(len(res), 2) # Right now 2 entries
+ assert_equal(len(res), 2 + self.num_cb_reward_addresses) # Right now 2 entries
other_addr = self.nodes[1].getnewaddress()
txid2 = self.nodes[0].sendtoaddress(other_addr, 0.1)
self.nodes[0].generate(1)
@@ -81,7 +86,7 @@ class ReceivedByTest(BitcoinTestFramework):
assert_equal(len(res), 1)
# Should be two entries though without filter
res = self.nodes[1].listreceivedbyaddress(0, True, True)
- assert_equal(len(res), 3) # Became 3 entries
+ assert_equal(len(res), 3 + self.num_cb_reward_addresses) # Became 3 entries
# Not on random addr
other_addr = self.nodes[0].getnewaddress() # note on node[0]! just a random addr