aboutsummaryrefslogtreecommitdiff
path: root/qa/rpc-tests
diff options
context:
space:
mode:
authorJonas Schnelli <jonas.schnelli@include7.ch>2014-12-25 08:57:16 +0100
committerGregory Maxwell <greg@xiph.org>2014-12-25 20:15:10 -0800
commit12d927a391b83041479f06e72051d37cc4e66655 (patch)
tree69a9e7354e1183e81b0fbcb844d615ec882ea28d /qa/rpc-tests
parent8024d67dae9da4a5259cddc0fa713146272f7aad (diff)
downloadbitcoin-12d927a391b83041479f06e72051d37cc4e66655.tar.xz
RPC test for immature balance
Diffstat (limited to 'qa/rpc-tests')
-rwxr-xr-xqa/rpc-tests/wallet.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/qa/rpc-tests/wallet.py b/qa/rpc-tests/wallet.py
index d99540b58a..f280ac380e 100755
--- a/qa/rpc-tests/wallet.py
+++ b/qa/rpc-tests/wallet.py
@@ -41,6 +41,10 @@ class WalletTest (BitcoinTestFramework):
self.nodes[0].setgenerate(True, 1)
+ walletinfo = self.nodes[0].getwalletinfo()
+ assert_equal(walletinfo['immature_balance'], 50)
+ assert_equal(walletinfo['balance'], 0)
+
self.sync_all()
self.nodes[1].setgenerate(True, 101)
self.sync_all()
@@ -54,6 +58,9 @@ class WalletTest (BitcoinTestFramework):
self.nodes[0].sendtoaddress(self.nodes[2].getnewaddress(), 11)
self.nodes[0].sendtoaddress(self.nodes[2].getnewaddress(), 10)
+ walletinfo = self.nodes[0].getwalletinfo()
+ assert_equal(walletinfo['immature_balance'], 0)
+
# Have node0 mine a block, thus he will collect his own fee.
self.nodes[0].setgenerate(True, 1)
self.sync_all()