From b05f8a90fd1fd034eb1d0d5345635c4c1d6693fa Mon Sep 17 00:00:00 2001 From: Roman Krasiuk Date: Wed, 13 Mar 2024 10:21:58 +0100 Subject: [PATCH] test: headers first stage (#7127) --- crates/primitives/src/stage/id.rs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/crates/primitives/src/stage/id.rs b/crates/primitives/src/stage/id.rs index bfd6e20fee..2f5de34eec 100644 --- a/crates/primitives/src/stage/id.rs +++ b/crates/primitives/src/stage/id.rs @@ -120,4 +120,11 @@ mod tests { assert!(!StageId::Execution.is_downloading_stage()); } + + // Multiple places around the codebase assume headers is the first stage. + // Feel free to remove this test if the assumption changes. + #[test] + fn stage_all_headers_first() { + assert_eq!(*StageId::ALL.first().unwrap(), StageId::Headers); + } }