Refactor chain- and epoch-specific state manager tests into a dedicated file

Aperta
#7,723 0 commenti 0 reazioni 1 assegnatario Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@akaladarshi ci sta già lavorando.

Dal 7/10/2026.

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

Summary

Move chain- and epoch-specific tests out of src/state_manager/utils.rs into a dedicated test file or test module. This is a follow-up refactor to PR #7709. It does not change state manager or RPC behavior.

Rationale

src/state_manager/utils.rs contains state-computation helpers and tests for specific network epochs. A dedicated test file will separate these responsibilities and make the snapshot-based tests easier to find and maintain.

Required changes

  • Move cargo_test_reward_distribution_calibnet_4109134 into a dedicated test file or test module.
  • Move the related chain- and epoch-specific replay and state-validation tests from state_compute::tests into the dedicated test organization.
  • Review the generated state-computation test inclusion and keep generated tests discoverable.
  • Keep reusable snapshot download and state preparation helpers available to the moved tests.
  • Preserve test names, assertions, Tokio runtime settings, and #[fickle::fickle] annotations.

Affected areas

  • src/state_manager/utils.rs, particularly state_compute::tests.
  • The new dedicated state manager test file or test module.
  • Test module declarations and generated-test inclusion, as needed.

Acceptance criteria

  • Chain- and epoch-specific tests no longer reside in src/state_manager/utils.rs.
  • The moved tests remain discoverable and retain their existing coverage.
  • Snapshot loading, state-root checks, reward accounting assertions, and cache assertions remain unchanged.
  • Relevant tests pass under the existing test workflow.
  • No production state manager or RPC behavior changes.

References

Lingua principale
Rust
Stelle
700
Fork
201
Merge medio
1g 17h
PR unite (30g)
65

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di ChainSafe/forest

Tutte le issue di ChainSafe/forest

Issue simili

Altre issue su Rust

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.