Three already-migrated crates still carry pockets of one-test-per-variant and self-referential tests the first pass didn't reach. Folding them into carbide-test-support tables puts the covered input space in one readable place and removes boilerplate; a few tests that only exercise a derive or restate a constant can go entirely. Test-only; no behavior change.
Scope
api-model
- Collapse the five
is_power_shelf_* tests (site_explorer/mod.rs) into one value_scenarios! table.
- Merge
build_version_partial_cmp_matches_cmp into the existing build_version_ordering table (machine/upgrade_policy.rs).
- Drop
test_display_matches_debug (controller_outcome.rs) -- Display is defined as Debug::fmt, so it cannot fail -- and the AssignStaticResult PartialEq-derive table (allocation_type.rs).
- Drop the two
IpAddr stdlib-format tests (machine/network.rs).
rpc
- Collapse the seven per-type
MachineCapability* Check tests into one check_cases table (model/machine/capabilities.rs).
- Drop the two
identity_config_try_from_proto_* tests that duplicate exact rows of the existing error-case table (model/tenant.rs).
uuid
- Merge the parallel
RackId / RackProfileId parse + serde tests (rack/mod.rs).
- Drop the tautological
*_conversions tests (transparent newtype: as_str == to_string == as_ref) and the test_db_column_name arm of typed_uuid_tests! (restates a constant against its own definition).
Acceptance
- Coverage preserved or improved; no production code changes.
cargo test green for the three crates; cargo clippy --all-features clean.
Size: S-M
Part of #2692.
Three already-migrated crates still carry pockets of one-test-per-variant and self-referential tests the first pass didn't reach. Folding them into
carbide-test-supporttables puts the covered input space in one readable place and removes boilerplate; a few tests that only exercise a derive or restate a constant can go entirely. Test-only; no behavior change.Scope
api-model
is_power_shelf_*tests (site_explorer/mod.rs) into onevalue_scenarios!table.build_version_partial_cmp_matches_cmpinto the existingbuild_version_orderingtable (machine/upgrade_policy.rs).test_display_matches_debug(controller_outcome.rs) --Displayis defined asDebug::fmt, so it cannot fail -- and theAssignStaticResultPartialEq-derive table (allocation_type.rs).IpAddrstdlib-format tests (machine/network.rs).rpc
MachineCapability*Checktests into onecheck_casestable (model/machine/capabilities.rs).identity_config_try_from_proto_*tests that duplicate exact rows of the existing error-case table (model/tenant.rs).uuid
RackId/RackProfileIdparse + serde tests (rack/mod.rs).*_conversionstests (transparent newtype:as_str==to_string==as_ref) and thetest_db_column_namearm oftyped_uuid_tests!(restates a constant against its own definition).Acceptance
cargo testgreen for the three crates;cargo clippy --all-featuresclean.Size: S-M
Part of #2692.