aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorWladimir J. van der Laan <laanwj@gmail.com>2017-09-19 17:45:10 +0200
committerWladimir J. van der Laan <laanwj@gmail.com>2017-09-19 17:46:05 +0200
commit4f7e37e26c5d1ca5421bb070e583aaa6b0c93d03 (patch)
tree0ffed811f101b267cd33e71643993ce84a3e629f /test
parent1ab1b687cb5870258add2b08169cd974f08ed032 (diff)
parentfadf31ef02b35f438ce2cf7048830f6974cdb515 (diff)
Merge #11307: wallet: Display non-HD error on first run
fadf31e wallet: Display non-HD error on first run (MarcoFalke) Pull request description: On current master a fresh wallet created with `-usehd=0` is silently created as HD wallet. An error should be displayed on the first run. Also, this restores a test that was removed in c22a53c Fixes: #11313 Tree-SHA512: 226a4129984324f88a431c7e2726383f6841711f0227d8e9f5b4f89d4bb9f2b8e922e6cf0a6f91d6efa747d139543a236b9f29326fc5d1e5d6f1dea2465d9b85
Diffstat (limited to 'test')
-rwxr-xr-xtest/functional/wallet-hd.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/functional/wallet-hd.py b/test/functional/wallet-hd.py
index 3af04c2279..5ef3bf5bff 100755
--- a/test/functional/wallet-hd.py
+++ b/test/functional/wallet-hd.py
@@ -20,6 +20,12 @@ class WalletHDTest(BitcoinTestFramework):
def run_test (self):
tmpdir = self.options.tmpdir
+ # Make sure can't switch off usehd after wallet creation
+ self.stop_node(1)
+ self.assert_start_raises_init_error(1, ['-usehd=0'], 'already existing HD wallet')
+ self.start_node(1)
+ connect_nodes_bi(self.nodes, 0, 1)
+
# Make sure we use hd, keep masterkeyid
masterkeyid = self.nodes[1].getwalletinfo()['hdmasterkeyid']
assert_equal(len(masterkeyid), 40)