fix: force mnsync to skip gov obj sync on reconnection

This commit is contained in:
UdjinM6 2024-06-04 18:16:18 +03:00
parent 08331bb950
commit 18328279ec
No known key found for this signature in database
GPG Key ID: 83592BD1400D58D9

View File

@ -8,7 +8,7 @@ import json
from test_framework.messages import uint256_to_string from test_framework.messages import uint256_to_string
from test_framework.test_framework import DashTestFramework from test_framework.test_framework import DashTestFramework
from test_framework.util import assert_equal, satoshi_round from test_framework.util import assert_equal, force_finish_mnsync, satoshi_round
class DashGovernanceTest (DashTestFramework): class DashGovernanceTest (DashTestFramework):
def set_test_params(self): def set_test_params(self):
@ -132,6 +132,9 @@ class DashGovernanceTest (DashTestFramework):
self.log.info("Reconnect isolated node and confirm the next ChainLock will let it sync") self.log.info("Reconnect isolated node and confirm the next ChainLock will let it sync")
self.reconnect_isolated_node(5, 0) self.reconnect_isolated_node(5, 0)
# Force isolated node to be fully synced so that it would not request gov objects when reconnected
assert_equal(self.nodes[5].mnsync("status")["IsSynced"], False)
force_finish_mnsync(self.nodes[5])
self.nodes[0].generate(1) self.nodes[0].generate(1)
self.bump_mocktime(156) self.bump_mocktime(156)
self.sync_blocks() self.sync_blocks()