iuna

iuna

iuna - experimental mainnet-candidate protocol
git clone https://getiuna.org/git/iuna.git
Log | Files | Refs | README | LICENSE

commit 0185e45df9eff5b4efab18eb1fc1755c25f5aea2
parent 06eb82196846bb74490d3be326e3eb90957f752d
Author: Joris Hartog <jorishartog@hotmail.com>
Date:   Wed,  2 Sep 2026 13:34:33 +0200

Update committee adversarial rejection tests

Diffstat:
Msrc/domain/adversarial_tests.rs | 56+++++++++++++++++++++++++++++++-------------------------
1 file changed, 31 insertions(+), 25 deletions(-)

diff --git a/src/domain/adversarial_tests.rs b/src/domain/adversarial_tests.rs @@ -2740,11 +2740,19 @@ fn finalizer_anchor_alone_requires_available_committee_signatures() { let finalizer = harness.wallet(&leader.owner).clone(); harness.submit_anchor_burn(&finalizer); - let without_committee = harness.finish_ticket_block_from_pending(0, Vec::new()); - assert_rejects( - harness.ledger.clone(), - without_committee, - "anchor-only block without available committee signatures", + let error = harness + .ledger + .prepare_next_block_with_burn_bundles( + finalizer.address(), + harness.ledger.tip().timestamp_ms.saturating_add(1), + Vec::new(), + ) + .unwrap_err(); + assert!( + error + .to_string() + .contains("not enough burn bundle signatures collected"), + "unexpected anchor-only preparation error: {error:#}" ); let bundles = harness.committee_bundles(); @@ -2789,26 +2797,24 @@ fn rank_one_committee_excludes_missed_rank_zero_owner_and_requires_remaining_slo let finalizer = harness.wallet(&rank_one).clone(); harness.submit_anchor_burn(&finalizer); - let without_committee = finish_prepared_block( - &finalizer, - harness - .ledger - .prepare_next_block_with_burn_bundles( - finalizer.address(), - harness - .ledger - .tip() - .timestamp_ms - .saturating_add(VDF_TARGET_BLOCK_MS * 2) - .saturating_add(1), - Vec::new(), - ) - .unwrap(), - ); - assert_rejects( - harness.ledger.clone(), - without_committee, - "rank-1 block without remaining committee signature", + let error = harness + .ledger + .prepare_next_block_with_burn_bundles( + finalizer.address(), + harness + .ledger + .tip() + .timestamp_ms + .saturating_add(VDF_TARGET_BLOCK_MS * 2) + .saturating_add(1), + Vec::new(), + ) + .unwrap_err(); + assert!( + error + .to_string() + .contains("not enough burn bundle signatures collected"), + "unexpected rank-1 preparation error: {error:#}" ); let member = committee