diff --git a/xmpp-parsers/src/carbons.rs b/xmpp-parsers/src/carbons.rs
index caf86353..07af9081 100644
--- a/xmpp-parsers/src/carbons.rs
+++ b/xmpp-parsers/src/carbons.rs
@@ -127,11 +127,39 @@ mod tests {
#[test]
fn test_serialize_received() {
- assert!(false);
+ let reference: Element = ""
+ .parse()
+ .unwrap();
+
+ let elem: Element = ""
+ .parse()
+ .unwrap();
+ let forwarded = Forwarded::try_from(elem).unwrap();
+
+ let received = Received {
+ forwarded: forwarded,
+ };
+
+ let serialized: Element = received.into();
+ assert_eq!(serialized, reference);
}
#[test]
fn test_serialize_sent() {
- assert!(false);
+ let reference: Element = ""
+ .parse()
+ .unwrap();
+
+ let elem: Element = ""
+ .parse()
+ .unwrap();
+ let forwarded = Forwarded::try_from(elem).unwrap();
+
+ let sent = Sent {
+ forwarded: forwarded,
+ };
+
+ let serialized: Element = sent.into();
+ assert_eq!(serialized, reference);
}
}