Skip to content

Commit

Permalink
mocknet: set mainnet consensus timing parameters (#10908)
Browse files Browse the repository at this point in the history
the default config produced by neard init gives us different times
between blocks than what we have on mainnet. Changing this to the
mainnet values will make the test conditions closer to production
  • Loading branch information
marcelo-gonzalez authored Apr 2, 2024
1 parent 79017e2 commit f37edc0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pytest/tests/mocknet/helpers/neard_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,10 @@ def neard_init(self, rpc_port, protocol_port, validator_id):
config['network']['skip_sync_wait'] = False
config['genesis_records_file'] = 'records.json'
config['rpc']['enable_debug_rpc'] = True
config['consensus']['min_block_production_delay']['secs'] = 1
config['consensus']['min_block_production_delay']['nanos'] = 300000000
config['consensus']['max_block_production_delay']['secs'] = 3
config['consensus']['max_block_production_delay']['nanos'] = 0
if self.is_traffic_generator():
config['archive'] = True
with open(self.tmp_near_home_path('config.json'), 'w') as f:
Expand Down

0 comments on commit f37edc0

Please sign in to comment.