Files
lighthouse/consensus/proto_array/src/bin.rs
Mac L a5e748f808 Use yaml_serde in place of deprecated serde_yaml (#9040)
`serde_yaml` is now deprecated. The API-compatible `yaml_serde` should be used instead.


  Replace `serde_yaml` with `yaml_serde`. This is purely mechanical as the API is 1-to-1.


Co-Authored-By: Mac L <mjladson@pm.me>
2026-03-29 18:39:20 +00:00

27 lines
994 B
Rust

use proto_array::fork_choice_test_definition::*;
use std::fs::File;
fn main() {
write_test_def_to_yaml("votes.yaml", get_votes_test_definition());
write_test_def_to_yaml("no_votes.yaml", get_no_votes_test_definition());
write_test_def_to_yaml("ffg_01.yaml", get_ffg_case_01_test_definition());
write_test_def_to_yaml("ffg_02.yaml", get_ffg_case_02_test_definition());
write_test_def_to_yaml(
"execution_status_01.yaml",
get_execution_status_test_definition_01(),
);
write_test_def_to_yaml(
"execution_status_02.yaml",
get_execution_status_test_definition_02(),
);
write_test_def_to_yaml(
"execution_status_03.yaml",
get_execution_status_test_definition_03(),
);
}
fn write_test_def_to_yaml(filename: &str, def: ForkChoiceTestDefinition) {
let file = File::create(filename).expect("Should be able to open file");
yaml_serde::to_writer(file, &def).expect("Should be able to write YAML to file");
}