@@ -536,12 +536,16 @@ def add_payload_vote_checks(store, block_root, test_steps):
536536def get_formatted_head_output (spec , store , head = None ):
537537 if head is None :
538538 head = spec .get_head (store )
539- slot = store .blocks [head .root ].slot
540- return {
541- "slot" : int (slot ),
539+ formatted_head = {
540+ "slot" : int (store .blocks [head .root ].slot ),
542541 "root" : encode_hex (head .root ),
543542 }
544543
544+ if is_post_gloas (spec ):
545+ formatted_head ["payload_status" ] = int (head .payload_status )
546+
547+ return formatted_head
548+
545549
546550def output_head_check (spec , store , test_steps ):
547551 head = spec .get_head (store )
@@ -555,10 +559,9 @@ def output_head_check(spec, store, test_steps):
555559
556560
557561def get_basic_store_checks (spec , store ):
558- head = spec .get_head (store )
559- checks = {
562+ return {
560563 "time" : int (store .time ),
561- "head" : get_formatted_head_output (spec , store , head ),
564+ "head" : get_formatted_head_output (spec , store ),
562565 "justified_checkpoint" : {
563566 "epoch" : int (store .justified_checkpoint .epoch ),
564567 "root" : encode_hex (store .justified_checkpoint .root ),
@@ -570,11 +573,6 @@ def get_basic_store_checks(spec, store):
570573 "proposer_boost_root" : encode_hex (store .proposer_boost_root ),
571574 }
572575
573- if is_post_gloas (spec ):
574- checks ["head_payload_status" ] = int (head .payload_status )
575-
576- return checks
577-
578576
579577def get_weighed_node_checks (spec , store , node ):
580578 if is_post_gloas (spec ):
0 commit comments