sasl: Document the reason for the unprefixed @lang test.

This commit is contained in:
Emmanuel Gil Peyrot 2019-01-13 11:56:40 +01:00
parent c2b7e19378
commit 635e8633a8

View file

@ -289,9 +289,11 @@ mod tests {
);
}
/// Some servers apparently use a non-namespaced 'lang' attribute, which is invalid as not part
/// of the schema. This tests whether we can parse it when disabling validation.
#[cfg(feature = "disable-validation")]
#[test]
fn failure_with_non_prefixed_text_lang() {
fn invalid_failure_with_non_prefixed_text_lang() {
let elem: Element = "<failure xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
<not-authorized xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
<text xmlns='urn:ietf:params:xml:ns:xmpp-sasl' lang='en'>Invalid username or password</text>