Skip to content

Commit

Permalink
Merge pull request #329 from AntelopeIO/GH-326-p2p-sync-test
Browse files Browse the repository at this point in the history
Test: P2P throttle test: Wait for begin block before measuring sync
  • Loading branch information
heifner authored Jun 28, 2024
2 parents 644d190 + f488e4c commit 09d979b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/p2p_sync_throttle_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def extractPrometheusMetric(connID: str, metric: str, text: str):

Print("Stand up cluster")
extraNodeosArgs = '--plugin eosio::prometheus_plugin --connection-cleanup-period 3'
# Custom topology is a line of singlely connected nodes from highest node number in sequence to lowest,
# Custom topology is a line of singly connected nodes from the highest node number in sequence to lowest,
# the reverse of the usual TestHarness line topology.
if cluster.launch(pnodes=pnodes, unstartedNodes=2, totalNodes=total_nodes, prodCount=prod_count,
topo='./tests/p2p_sync_throttle_test_shape.json', delay=delay, activateIF=activateIF,
Expand Down Expand Up @@ -205,6 +205,7 @@ def extractPrometheusMetric(connID: str, metric: str, text: str):
'block_sync_bytes_sent',
response)
Print(f'End sync throttling bytes sent: {endSyncThrottlingBytesSent}')
assert throttledNode.waitForBlock(beginLargeBlocksHeadBlock, timeout=90), f'Wait for begin block {beginLargeBlocksHeadBlock} on throttled sync node timed out'
# Throttled node is connecting to a listen port with a block sync throttle applied so it will receive
# blocks more slowly during syncing than an unthrottled node.
wasThrottled = False
Expand Down

0 comments on commit 09d979b

Please sign in to comment.