remove unused test functions (#15375)

Mariano removed the test using these functions a long time ago
This commit is contained in:
Arvid Norberg 2023-05-25 21:05:08 +02:00 committed by GitHub
parent 60d11a435f
commit 6effab5dd2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 0 additions and 27 deletions

View File

@ -23,33 +23,6 @@ from chia.util.generator_tools import get_block_header
from chia.util.ints import uint32, uint64
def count_sub_epochs(blockchain, last_hash) -> int:
curr = blockchain._sub_blocks[last_hash]
count = 0
while True:
if curr.height == 0:
break
# next sub block
curr = blockchain._sub_blocks[curr.prev_hash]
# if end of sub-epoch
if curr.sub_epoch_summary_included is not None:
count += 1
return count
def get_prev_ses_block(sub_blocks, last_hash) -> Tuple[BlockRecord, int]:
curr = sub_blocks[last_hash]
blocks = 1
while curr.height != 0:
# next sub block
curr = sub_blocks[curr.prev_hash]
# if end of sub-epoch
if curr.sub_epoch_summary_included is not None:
return curr, blocks
blocks += 1
assert False
async def load_blocks_dont_validate(
blocks, constants: ConsensusConstants
) -> Tuple[