test(small crates): adopt carbide-test-support across five parser/serde suites#2745
Conversation
…de suites
Five crates each proved a single parser or serde mapping one `#[test]` per case;
this folds each into one `carbide-test-support` table over a named row:
- `carbide-dns`: the gRPC-code -> DNS-response-code classifier, extended from a
hand-rolled loop to the full 17-variant `tonic::Code` set.
- `bms-dsx-exchange`: metadata-topic parsing (rack / heartbeat / value-topic
derivation) over a `Message { topic, payload }` row.
- `carbide-dsx-exchange-consumer`: point-path extraction and `FaultValue` serde,
plus newly-added `LeakPointType` probe-id / description tables.
- `carbide-kms-provider`: the config-file key-source loader (valid, bad-base64,
wrong-length) over a `KeySource` row.
- `carbide-rvs`: `eval_sotpath` and `resolve_for_scenario`, the latter now
asserting the full `(output_path, url)` vec rather than a length and an index.
Errors compare as `Fails` (these error types aren't `PartialEq`, so each run
closure maps to a string); the expected variant or reason is named in the group
label. Tests that mutate process env or exercise a different input shape stay on
their own. Adds `carbide-test-support` as a dev-dependency to the four crates that
lacked it. No production change; the tests run green.
Signed-off-by: Chet Nichols III <chetn@nvidia.com>
|
@coderabbitai PTAL, thanks! |
|
Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
|
Important Review skippedNo new commits to review since the last review. ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
WalkthroughFive crates ( Changescarbide-test-support Wave 2: Table-driven test migration
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related issues
Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
✅ Action performedReview finished.
|
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
@coderabbitai full review |
✅ Action performedFull review finished. |
|
@coderabbitai review |
✅ Action performedReview finished.
|
🔍 Container Scan Summary
Per-CVE detail lives in the per-service |
Wave 2 of the carbide-test-support integration (#2692) -- the small-crate bundle.
Five crates each proved a single parser/serde mapping one
#[test]per case; each folds into one table over a named row:carbide-dns: gRPC-code → DNS-response-code classifier, extended to the full 17-varianttonic::Codeset.bms-dsx-exchange: metadata-topic parsing over aMessage { topic, payload }row.carbide-dsx-exchange-consumer: point-path extraction +FaultValueserde, plus newLeakPointTypeprobe-id/description tables.carbide-kms-provider: config-file key-source loader over aKeySourcerow.carbide-rvs:eval_sotpath+resolve_for_scenario(now asserting the full(output_path, url)vec).Errors compare as
Fails(these error types aren'tPartialEq); env-mutating and different-shape tests stay separate. Adds the dev-dep to the four crates that lacked it. No production change. Verified:--libtests pass in all five,clippy --locked --all-targets --all-featuresclean, nightly rustfmt clean.Addresses #2731.