add intial focil test

This commit is contained in:
Eitan Seri-Levi
2025-02-04 16:03:53 +02:00
parent 88afbb39be
commit 7414f485a3
4 changed files with 131 additions and 1 deletions

View File

@@ -845,7 +845,9 @@ impl<E: EthSpec> BeaconState<E> {
let epoch = slot.epoch(E::slots_per_epoch());
let current_epoch = self.current_epoch();
let next_epoch = current_epoch.safe_add(1)?;
if epoch != current_epoch || epoch != next_epoch {
// TODO(focil) review this logic
if epoch != current_epoch && epoch != next_epoch {
return Err(Error::SlotOutOfBounds);
}