test: round-trip the no_std IntentBody derive probe#571
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds a
#[cfg(test)]round-trip test to the no-std-probe, exercisingIntentBody::to_bytes/from_bytes(happy path, unknown version, empty input) viavidere_sdk::BodyError. Retitles the module doc to scope theno_stdclaim to derive hygiene only: the derive expands under#![no_std]naming only::coreand the SDK's__privatere-exports, and the round-trip test now proves the generated codec is correct, not merely that it expands.Why
Closes the gap identified in review of #451: the probe derived
IntentBodybut never calledto_bytes/from_bytes, so it proved macro expansion, not codec correctness. Per the issue's alternative,videre-sdkstays std-bearing (the real target iswasm32-wasip2, not bare-metal), so the claim is scoped down rather than chasing ano_stdSDK conversion or a bare-metal CI target that this SDK does not need.Testing
cargo fmt --all -- --check; cargo clippy --workspace --all-targets --all-features --locked -- -D warnings; wasm release build of all 18 guest modules plus a separate cow-venue --features cow-venue/adapter build, with a wasm count assert of 18; cargo nextest run --workspace --all-features --no-fail-fast --locked (804 passed, 1 skipped, 0 failed); cargo test --doc --workspace --all-features --locked; RUSTDOCFLAGS="-D warnings" cargo doc --workspace --no-deps --locked; ./scripts/check-venue-agnostic.sh; ./scripts/check-cow-orderbook-only.sh. All steps passed.
AI Assistance
Implemented with Claude Code.
Closes #521