mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-01-25 02:33:24 -03:00
Merge bitcoin/bitcoin#26723: test: call keypoolrefill
with priv key disabled should throw an error
ec63a4892e
test: call `keypoolrefill` with private keys disabled should throw an error (brunoerg) Pull request description: This PR adds test coverage for the following error:cb32328d1b/src/wallet/rpc/addresses.cpp (L332-L334)
ACKs for top commit: aureleoules: ACKec63a4892e
Tree-SHA512: b5deda8981ff472f290e6e16c8723a58e02cbe099afd1f672c099f4add0a1d9b192b11a2c3f0e11b96794671f6b9efa75812b7a174248d7c58d7fd7d3310e7b9
This commit is contained in:
commit
8ab19237e1
1 changed files with 3 additions and 0 deletions
|
@ -204,6 +204,9 @@ class KeyPoolTest(BitcoinTestFramework):
|
|||
res = w2.walletcreatefundedpsbt(inputs=[], outputs=[{destination: 0.00010000}], options={"subtractFeeFromOutputs": [0], "feeRate": 0.00010, "changeAddress": addr.pop()})
|
||||
assert_equal("psbt" in res, True)
|
||||
|
||||
if not self.options.descriptors:
|
||||
msg = "Error: Private keys are disabled for this wallet"
|
||||
assert_raises_rpc_error(-4, msg, w2.keypoolrefill, 100)
|
||||
|
||||
if __name__ == '__main__':
|
||||
KeyPoolTest().main()
|
||||
|
|
Loading…
Add table
Reference in a new issue