xmpp-parsers/mam: Use .is_empty() instead of Vec’s PartialEq.

This commit is contained in:
Emmanuel Gil Peyrot 2020-12-10 20:44:54 +01:00
parent 63d940b339
commit 71b995731a

View file

@ -313,8 +313,8 @@ mod tests {
.parse()
.unwrap();
let prefs = Prefs::try_from(elem).unwrap();
assert_eq!(prefs.always, vec!());
assert_eq!(prefs.never, vec!());
assert!(prefs.always.is_empty());
assert!(prefs.never.is_empty());
let elem: Element = r#"
<prefs xmlns='urn:xmpp:mam:2' default='roster'>
@ -325,8 +325,8 @@ mod tests {
.parse()
.unwrap();
let prefs = Prefs::try_from(elem).unwrap();
assert_eq!(prefs.always, vec!());
assert_eq!(prefs.never, vec!());
assert!(prefs.always.is_empty());
assert!(prefs.never.is_empty());
}
#[test]