Dramatically speed up tests

This commit is contained in:
Carl Beekhuizen 2019-05-22 12:40:57 +02:00
parent 9058647b67
commit 271f615873
No known key found for this signature in database
GPG Key ID: D05CA176D0020646
3 changed files with 3 additions and 1 deletions

View File

@ -74,6 +74,8 @@ PERSISTENT_COMMITTEE_PERIOD: 2048
MAX_EPOCHS_PER_CROSSLINK: 64
# 2**2 (= 4) epochs 25.6 minutes
MIN_EPOCHS_TO_INACTIVITY_PENALTY: 4
# [customized] 2**12 (= 4,096) epochs 18 days
EARLY_DERIVED_SECRET_PENALTY_MAX_FUTURE_EPOCHS: 4096
# State list lengths

View File

@ -114,7 +114,7 @@ def objects_to_spec(functions, constants, ssz_objects, imports):
constants_spec = '\n'.join(map(lambda x: '%s = %s' % (x, constants[x]),constants))
ssz_objects_instantiation_spec = '\n'.join(map(lambda x: '%s = SSZType(%s)' % (x, ssz_objects[x][:-1]), ssz_objects))
ssz_objects_reinitialization_spec = '\n'.join(
map(lambda x: ' global_vars[%s] = SSZType(%s })' % (x, re.sub('( ){4}', ' '*8, ssz_objects[x][:-2])), ssz_objects))
map(lambda x: ' global_vars[\'%s\'] = SSZType(%s })' % (x, re.sub('( ){4}', ' '*8, ssz_objects[x][:-2])), ssz_objects))
ssz_objects_reinitialization_spec = (
'def init_SSZ_types():\n global_vars = globals()\n'
+ ssz_objects_reinitialization_spec