diff --git a/testing/endtoend/evaluators/operations.go b/testing/endtoend/evaluators/operations.go index 8228ad31256d..e6f088677316 100644 --- a/testing/endtoend/evaluators/operations.go +++ b/testing/endtoend/evaluators/operations.go @@ -29,8 +29,6 @@ import ( "google.golang.org/protobuf/types/known/emptypb" ) -// churnLimit is normally 4 unless the validator set is extremely large. -var churnLimit = 4 var depositValCount = e2e.DepositCount var numOfExits = 2 @@ -39,7 +37,7 @@ var depositsInBlockStart = params.E2ETestConfig().EpochsPerEth1VotingPeriod * 2 // deposits included + finalization + MaxSeedLookahead for activation. var depositActivationStartEpoch = depositsInBlockStart + 2 + params.E2ETestConfig().MaxSeedLookahead -var depositEndEpoch = depositActivationStartEpoch + primitives.Epoch(math.Ceil(float64(depositValCount)/float64(churnLimit))) +var depositEndEpoch = depositActivationStartEpoch + primitives.Epoch(math.Ceil(float64(depositValCount)/float64(params.BeaconConfig().MinPerEpochChurnLimit))) var exitSubmissionEpoch = primitives.Epoch(7) // ProcessesDepositsInBlocks ensures the expected amount of deposits are accepted into blocks. @@ -249,8 +247,8 @@ func activatesDepositedValidators(ec *e2etypes.EvaluationContext, conns ...*grpc return fmt.Errorf("missing %d validators for post-genesis deposits", len(expected)) } - if deposits != churnLimit { - return fmt.Errorf("expected %d deposits to be processed in epoch %d, received %d", churnLimit, epoch, deposits) + if deposits != int(params.BeaconConfig().MinPerEpochChurnLimit) { + return fmt.Errorf("expected %d deposits to be processed in epoch %d, received %d", params.BeaconConfig().MinPerEpochChurnLimit, epoch, deposits) } if lowBalance > 0 {