minidom: Don't prepend xml prelude in writer. Add new API

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
Maxime “pep” Buquet 2019-11-10 01:01:34 +01:00
commit 141d11ad38
No known key found for this signature in database
GPG key ID: DEDA74AEECA9D0F2
6 changed files with 29 additions and 11 deletions

View file

@ -607,7 +607,7 @@ mod tests {
assert_eq!(html, "Hello world!");
let elem = Element::from(parsed2);
assert_eq!(String::from(&elem), "<?xml version=\"1.0\" encoding=\"utf-8\"?><html xmlns=\"http://jabber.org/protocol/xhtml-im\"><body xmlns=\"http://www.w3.org/1999/xhtml\">Hello world!</body></html>");
assert_eq!(String::from(&elem), "<html xmlns=\"http://jabber.org/protocol/xhtml-im\"><body xmlns=\"http://www.w3.org/1999/xhtml\">Hello world!</body></html>");
}
#[test]