test(bmc): consolidate vendor ownership#4074
Conversation
Move canonical vendor matrices beside their production owners and replace the duplicated compute-tray adapters with one exhaustive conversion. Trim wrapper and integration assertions to their own responsibilities, remove unused helpers, and cover previously untested parsing, transport, and adapter branches. NVIDIA#4069 Signed-off-by: Chet Nichols III <chetn@nvidia.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (17)
💤 Files with no reviewable changes (2)
Summary by CodeRabbit
WalkthroughThe change consolidates BMC vendor parsing and classification tests, centralizes BMC-to-compute-tray conversion, adds adapter coverage, removes duplicated vendor assertions, and refactors SSH vendor serialization and detection tests. ChangesCanonical vendor contracts
Compute-tray conversion
Hardware and Redfish adapters
SSH vendor boundaries
Estimated code review effort: 3 (Moderate) | ~25 minutes Possibly related PRs
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
🌿 Preview your docs: https://nvidia-preview-pull-request-4074.docs.buildwithfern.com/infra-controller |
|
@coderabbitai full review, thanks! |
|
🐇🔍 ✅ Action performedFull review finished. |
Canonical BMC vendor rules were spread across direct owners, wrapper tests, duplicate compute-tray adapters, and repeated integration assertions. This moves each matrix beside the production code it verifies, removes proven copies and unused helpers, and fills the vendor boundaries that had no direct coverage.
Related issues
Closes #4069.
Part of #3914.
Type of Change
Breaking Changes
Testing
Unit tests added/updated
Integration tests added/updated
Manual testing performed
No testing required (docs, internal refactor, etc.)
Post-rebase
cargo llvm-covunion across the nine focused package/filter invocations -- 44 passedcargo make format-nightlycargo make clippycargo make carbide-lintsIndependent diff review -- no code findings
Local CodeRabbit review -- no findings
Local Claude review -- no correctness or compile defects
Additional Notes
Ownership and duplicate control
bmc-vendornow owns complete parsing, DMI classification, display, Pascal-case, and retained predicate tables.BMCVendor -> ComputeTrayVendorfunctions become one exhaustiveFromimplementation besideComputeTrayVendor.Coverage
The measurements select the production vendor owners and adapters across
bmc-vendor, API-model, component-manager, SSH-console, BMC-explorer, Redfish, and API-core.The converted checkpoint preserves every covered production line and region while duplicate/dead production removal reduces the selected denominator by six functions, 31 lines, and 37 regions. The expanded tables then add 106 covered lines and 127 covered regions, reaching every selected production function, line, and region.
The final expanded union was rerun after rebasing onto
b01a70adf, which already contains #4030, and produced the same 24/24 function, 182/182 line, and 227/227 region totals.