From 4f3fc484a4e7830bef7675a9301ae687b494129d Mon Sep 17 00:00:00 2001 From: Damien Lachaume <135982616+dlachaume@users.noreply.github.com> Date: Wed, 15 May 2024 19:09:29 +0200 Subject: [PATCH] fix: prevent registering signers if registration round is closed --- .../src/stress_test/aggregator_helpers.rs | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/mithril-test-lab/mithril-end-to-end/src/stress_test/aggregator_helpers.rs b/mithril-test-lab/mithril-end-to-end/src/stress_test/aggregator_helpers.rs index ce032b377a3..ecfac461ee3 100644 --- a/mithril-test-lab/mithril-end-to-end/src/stress_test/aggregator_helpers.rs +++ b/mithril-test-lab/mithril-end-to-end/src/stress_test/aggregator_helpers.rs @@ -60,6 +60,14 @@ pub async fn bootstrap_aggregator( restart_aggregator_and_move_one_epoch_forward(&mut aggregator, current_epoch, args).await?; + fake_signer::try_register_signer_until_registration_round_is_open( + &aggregator, + &signers_fixture.signers()[0], + *current_epoch + 1, + Duration::from_secs(60), + ) + .await?; + info!(">> Send the Signer Key Registrations payloads for the genesis signers"); let errors = fake_signer::register_signers_to_aggregator( &aggregator, @@ -69,6 +77,14 @@ pub async fn bootstrap_aggregator( .await?; assert_eq!(0, errors); + fake_signer::try_register_signer_until_registration_round_is_open( + &aggregator, + &signers_fixture.signers()[0], + *current_epoch + 1, + Duration::from_secs(60), + ) + .await?; + restart_aggregator_and_move_one_epoch_forward(&mut aggregator, current_epoch, args).await?; info!(">> Send the Signer Key Registrations payloads for next genesis signers");