I'm trying to write a test case for some code that uses rtnetlink. I need to construct a NeighborMessage from netlink-packet-route. Since that is marked as #[non_exhaustive] I cannot construct one directly. I am constructing a default message and mutate it like so:
let mut msg = NeighborMessage::default();
msg.headers = ...;
msg.attributes = ...;
However when I look through the documentation I see a LinkMessageBuilder for LinkMessage and a RouteMessageBuilder for RouteMessage. It makes me expect to see a NeighborMessageBuilder. Should there be?
I'm trying to write a test case for some code that uses
rtnetlink. I need to construct aNeighborMessagefromnetlink-packet-route. Since that is marked as#[non_exhaustive]I cannot construct one directly. I am constructing a default message and mutate it like so:However when I look through the documentation I see a
LinkMessageBuilderforLinkMessageand aRouteMessageBuilderforRouteMessage. It makes me expect to see aNeighborMessageBuilder. Should there be?