Allow setmocktime in regtest
Signed-off-by: Anthony Fieroni <bvbfan@abv.bg>
This commit is contained in:
parent
9b17209c44
commit
b4bc48552c
1 changed files with 1 additions and 1 deletions
|
@ -350,7 +350,7 @@ static UniValue setmocktime(const JSONRPCRequest& request)
|
|||
RPCExamples{""},
|
||||
}.Check(request);
|
||||
|
||||
if (!Params().MineBlocksOnDemand())
|
||||
if (Params().NetworkIDString() != CBaseChainParams::REGTEST)
|
||||
throw std::runtime_error("setmocktime for regression testing (-regtest mode) only");
|
||||
|
||||
// For now, don't change mocktime if we're in the middle of validation, as
|
||||
|
|
Loading…
Reference in a new issue