Three more already-migrated crates carry one-function-per-variant clusters and a few tests that assert nothing. Collapsing the clusters into tables makes each decision matrix readable at a glance; the no-assertion and stdlib tests can go. Test-only; no behavior change.
Scope
ib-fabric
- Collapse the 12
should_track_port_as_down_* functions into one table (lib.rs); fold the three ib_port_down_alert_* tests into a projection table.
admin-cli
- Collapse the six
dpu_mode per-variant parse tests into one scenarios! table (expected_machines/tests.rs).
- Rewrite
health_override_templates_value_enum (machine/tests.rs) so it yields the variant rather than mapping a string back to itself, and so a newly-added variant can't slip silently past the _ => unreachable!() arm.
- Merge
boot_override parse_get / parse_clear; drop the no-assertion routing tests (firmware / dpu parse_*) and the two assert_dispatch::<T>() compile-checks (cfg/dispatch.rs).
libmlx
- Collapse the four near-duplicate
traits_tests.rs function pairs.
- Delete the five
exec_options_tests.rs::advanced_tests::test_sample*_config functions (they set builder fields then re-assert them).
- Remove the construction-then-drop "creation" / "default" tests and the
str::contains / Command-debug stdlib tests (tests/lockdown/, tests/runner/).
Acceptance
- Coverage preserved or improved; the
value_enum rewrite fails when a variant is added without a row.
cargo test green for the three crates; cargo clippy --all-features clean.
Size: S-M
Part of #2692.
Three more already-migrated crates carry one-function-per-variant clusters and a few tests that assert nothing. Collapsing the clusters into tables makes each decision matrix readable at a glance; the no-assertion and stdlib tests can go. Test-only; no behavior change.
Scope
ib-fabric
should_track_port_as_down_*functions into one table (lib.rs); fold the threeib_port_down_alert_*tests into a projection table.admin-cli
dpu_modeper-variant parse tests into onescenarios!table (expected_machines/tests.rs).health_override_templates_value_enum(machine/tests.rs) so it yields the variant rather than mapping a string back to itself, and so a newly-added variant can't slip silently past the_ => unreachable!()arm.boot_overrideparse_get/parse_clear; drop the no-assertion routing tests (firmware/dpuparse_*) and the twoassert_dispatch::<T>()compile-checks (cfg/dispatch.rs).libmlx
traits_tests.rsfunction pairs.exec_options_tests.rs::advanced_tests::test_sample*_configfunctions (they set builder fields then re-assert them).str::contains/Command-debug stdlib tests (tests/lockdown/,tests/runner/).Acceptance
value_enumrewrite fails when a variant is added without a row.cargo testgreen for the three crates;cargo clippy --all-featuresclean.Size: S-M
Part of #2692.