Open TTWNO opened 4 months ago
Attention: Patch coverage is 94.87603%
with 31 lines
in your changes missing coverage. Please review.
Project coverage is 84.67%. Comparing base (
bfa3bc4
) to head (cb70e23
).
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Shout out to our extensive tests that caught a ton of the mistakes I was making along the way! I would have forgot to add the signature check if we didn't have a test specifically that matched the interface+member but gave a blank body.
Rebased on main.
Summary
Split
BusProperties
into theconst &'static str
s (still calledBusProperties
), and message conversion:MessageConversion
(TODO: name).All trivial events (where they contain only the field
item
) now implementFrom<ObjectRef>
.All events that implement
From<ObjectRef>
get theirMessageConversion
implementation for free (blanket impl).Rename:
from_message_parts(ObjectRef, Self::Body)
, totry_from_message_unchecked(&zbus::Message)
An additional check was added to all implementations of
From<&zbus::Message>
(the macro) requireing that the body signature match the event's body signature—this supplements the xisitng checks on the interface and member.Commits
TODO
Event
and interface-grouped enums use_unchecked
instead ofTryFrom<&Message>
_unchecked
variant deserialization for interface-grouped enums, which will not check the validity of the interface before continuing,