wallet: fix importdescriptor silent fail

This commit is contained in:
Ivan Metlushko
2020-10-15 18:02:58 +07:00
parent 711ddce943
commit 538be4219a
3 changed files with 16 additions and 2 deletions

View File

@@ -207,6 +207,15 @@ class ImportDescriptorsTest(BitcoinTestFramework):
success=False,
error_code=-4,
error_message='Cannot import private keys to a wallet with private keys disabled')
self.log.info("Should not import a descriptor with hardened derivations when private keys are disabled")
self.test_importdesc({"desc": descsum_create("wpkh(" + xpub + "/1h/*)"),
"timestamp": "now",
"range": 1},
success=False,
error_code=-4,
error_message='Cannot expand descriptor. Probably because of hardened derivations without private keys provided')
for address in addresses:
test_address(w1,
address,