compat mode that relaxes some of the check_* macros

This commit is contained in:
Astro 2018-12-30 00:36:29 +01:00
commit 95f4ade4ba
17 changed files with 70 additions and 31 deletions

View file

@ -289,6 +289,7 @@ mod tests {
);
}
#[cfg(feature = "compat")]
#[test]
fn failure_with_non_prefixed_text_lang() {
let elem: Element = "<failure xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
@ -299,9 +300,5 @@ mod tests {
.unwrap();
let failure = Failure::try_from(elem).unwrap();
assert_eq!(failure.defined_condition, DefinedCondition::NotAuthorized);
assert_eq!(
failure.texts["en"],
String::from("Invalid username or password")
);
}
}