Skip to content

Commit

Permalink
[RPC] Add DMN support to listmasternodes
Browse files Browse the repository at this point in the history
  • Loading branch information
random-zebra committed May 23, 2021
1 parent 064f774 commit aa867d5
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions test/functional/tiertwo_governance_sync_basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,13 @@ def check_mns_status(self, node, txhash):
assert_equal(status["dmnstate"]["PoSePenalty"], 0)
assert_equal(status["status"], "Ready")

def check_mn_list(self, node, txHashSet):
# check masternode list from node
mnlist = node.listmasternodes()
assert_equal(len(mnlist), 3)
foundHashes = set([mn["txhash"] for mn in mnlist if mn["txhash"] in txHashSet])
assert_equal(len(foundHashes), len(txHashSet))

def check_budget_finalization_sync(self, votesCount, status):
for i in range(0, len(self.nodes)):
node = self.nodes[i]
Expand Down Expand Up @@ -108,6 +115,9 @@ def check_budgetprojection(self, expected):
def run_test(self):
self.enable_mocktime()
self.setup_3_masternodes_network()
txHashSet = set([self.mnOneTxHash, self.mnTwoTxHash, self.proRegTx])
# check mn list from miner
self.check_mn_list(self.miner, txHashSet)

# check status of masternodes
self.check_mns_status_legacy(self.remoteOne, self.mnOneTxHash)
Expand Down

0 comments on commit aa867d5

Please sign in to comment.