From 8de14336f5133e1a068ff2b13bbff798fc75a232 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maxime=20=E2=80=9Cpep=E2=80=9D=20Buquet?= Date: Mon, 14 Aug 2023 21:59:27 +0200 Subject: [PATCH] jid: Add test for Jid::Full ser/de MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Maxime “pep” Buquet --- jid/src/lib.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/jid/src/lib.rs b/jid/src/lib.rs index 59de6cd7..12ff5787 100644 --- a/jid/src/lib.rs +++ b/jid/src/lib.rs @@ -917,6 +917,10 @@ mod tests { fn jid_ser_de() { let jid: Jid = Jid::new("node@domain").unwrap(); serde_test::assert_tokens(&jid, &[serde_test::Token::Str("node@domain")]); + + let jid: Jid = Jid::new("node@domain/resource").unwrap(); + serde_test::assert_tokens(&jid, &[serde_test::Token::Str("node@domain/resource")]); + let jid: BareJid = BareJid::new("node@domain").unwrap(); serde_test::assert_tokens(&jid, &[serde_test::Token::Str("node@domain")]);