From 3b2352baedd9b909576570bd3681035c5ff6dda2 Mon Sep 17 00:00:00 2001 From: Luke Parker Date: Sun, 16 Oct 2022 09:09:05 -0400 Subject: [PATCH] Fix test --- substrate/tendermint/tests/ext.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/substrate/tendermint/tests/ext.rs b/substrate/tendermint/tests/ext.rs index fe773247..fb1949da 100644 --- a/substrate/tendermint/tests/ext.rs +++ b/substrate/tendermint/tests/ext.rs @@ -26,14 +26,14 @@ impl Weights for TestWeights { type ValidatorId = TestValidatorId; fn total_weight(&self) -> u64 { - 5 + 4 } fn weight(&self, id: TestValidatorId) -> u64 { - [1, 1, 1, 1, 1][usize::try_from(id).unwrap()] + [1; 4][usize::try_from(id).unwrap()] } fn proposer(&self, number: BlockNumber, round: Round) -> TestValidatorId { - TestValidatorId::try_from((number.0 + u32::from(round.0)) % 5).unwrap() + TestValidatorId::try_from((number.0 + u32::from(round.0)) % 4).unwrap() } }