mirror of https://github.com/bitcoin/bitcoin
Bugfix: RPC: blockchain: Actually include "temporary" flag in listprunelocks result
This commit is contained in:
parent
427353a89d
commit
31874a0aee
|
@ -809,6 +809,7 @@ static RPCHelpMan listprunelocks()
|
|||
heights_uv.push_back(lock_info.height_last);
|
||||
}
|
||||
prune_lock_uv.pushKV("height", heights_uv);
|
||||
prune_lock_uv.pushKV("temporary", lock_info.temporary);
|
||||
locks_uv.push_back(prune_lock_uv);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -329,7 +329,7 @@ class PruneTest(BitcoinTestFramework):
|
|||
"desc": "Testing",
|
||||
"height": [2, 2],
|
||||
})
|
||||
assert_equal(node.listprunelocks(), {'prune_locks': [{'id': 'test', 'desc': 'Testing', 'height': [2, 2]}]})
|
||||
assert_equal(node.listprunelocks(), {'prune_locks': [{'id': 'test', 'desc': 'Testing', 'height': [2, 2], 'temporary': False}]})
|
||||
prune(500)
|
||||
assert has_block(0), "blk00000.dat is missing when should still be there"
|
||||
node.setprunelock("test", {}) # delete prune lock
|
||||
|
|
Loading…
Reference in New Issue