Skip to content

Commit d235b8c

Browse files
committed
added blocks check for miner1
1 parent 6ce5d02 commit d235b8c

File tree

1 file changed

+19
-4
lines changed
  • testnet/stacks-node/src/tests/signer

1 file changed

+19
-4
lines changed

testnet/stacks-node/src/tests/signer/v0.rs

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10289,10 +10289,25 @@ fn disallow_reorg_within_first_proposal_burn_block_timing_secs_but_more_than_one
1028910289
)
1029010290
.expect("Timed out waiting for a block proposal to be rejected");
1029110291

10292-
assert_eq!(
10293-
get_chain_info(&conf_1).stacks_tip_height,
10294-
block_n_height + 3
10295-
);
10292+
// check only 1 block from miner1 has been added after the epoch3 boot
10293+
let miner1_blocks_after_boot_to_epoch3 = get_nakamoto_headers(&conf_1)
10294+
.into_iter()
10295+
.filter(|block| {
10296+
// skip first nakamoto block
10297+
if block.stacks_block_height == stacks_height_before {
10298+
return false;
10299+
}
10300+
let nakamoto_block_header = block.anchored_header.as_stacks_nakamoto().unwrap();
10301+
miner_pk_1
10302+
.verify(
10303+
nakamoto_block_header.miner_signature_hash().as_bytes(),
10304+
&nakamoto_block_header.miner_signature,
10305+
)
10306+
.unwrap()
10307+
})
10308+
.count();
10309+
10310+
assert_eq!(miner1_blocks_after_boot_to_epoch3, 1);
1029610311

1029710312
info!("------------------------- Shutdown -------------------------");
1029810313
miners.shutdown();

0 commit comments

Comments
 (0)