mirror of
https://gitlab.com/xmpp-rs/xmpp-rs.git
synced 2024-07-12 22:21:53 +00:00
Test the size of every struct defined here.
This commit is contained in:
parent
9cb4f00341
commit
40aedcf184
43 changed files with 295 additions and 0 deletions
|
@ -20,6 +20,11 @@ mod tests {
|
|||
use minidom::Element;
|
||||
use error::Error;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Attention, 0);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<attention xmlns='urn:xmpp:attention:0'/>".parse().unwrap();
|
||||
|
|
|
@ -98,6 +98,11 @@ impl From<Bind> for Element {
|
|||
mod tests {
|
||||
use super::*;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Bind, 80);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'/>".parse().unwrap();
|
||||
|
|
|
@ -98,6 +98,14 @@ generate_empty_element!(
|
|||
mod tests {
|
||||
use super::*;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(BlocklistRequest, 0);
|
||||
assert_size!(BlocklistResult, 24);
|
||||
assert_size!(Block, 24);
|
||||
assert_size!(Unblock, 24);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<blocklist xmlns='urn:xmpp:blocking'/>".parse().unwrap();
|
||||
|
|
|
@ -74,6 +74,13 @@ mod tests {
|
|||
use minidom::Element;
|
||||
use compare_elements::NamespaceAwareCompare;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Conference, 152);
|
||||
assert_size!(Url, 48);
|
||||
assert_size!(Storage, 48);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn empty() {
|
||||
let elem: Element = "<storage xmlns='storage:bookmarks'/>".parse().unwrap();
|
||||
|
|
|
@ -211,6 +211,11 @@ mod tests {
|
|||
use caps;
|
||||
use base64;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Caps, 104);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_parse() {
|
||||
let elem: Element = "<c xmlns='http://jabber.org/protocol/caps' hash='sha-256' node='coucou' ver='K1Njy3HZBThlo4moOD5gBGhn0U0oK7/CbfLlIUDi6o4='/>".parse().unwrap();
|
||||
|
|
|
@ -37,6 +37,11 @@ mod tests {
|
|||
use error::Error;
|
||||
use ns;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(ChatState, 1);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<active xmlns='http://jabber.org/protocol/chatstates'/>".parse().unwrap();
|
||||
|
|
|
@ -47,6 +47,11 @@ mod tests {
|
|||
use try_from::TryFrom;
|
||||
use minidom::Element;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Handshake, 24);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<handshake xmlns='jabber:component:accept'/>".parse().unwrap();
|
||||
|
|
|
@ -268,6 +268,15 @@ impl From<DataForm> for Element {
|
|||
mod tests {
|
||||
use super::*;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Option_, 48);
|
||||
assert_size!(FieldType, 1);
|
||||
assert_size!(Field, 128);
|
||||
assert_size!(DataFormType, 1);
|
||||
assert_size!(DataForm, 104);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<x xmlns='jabber:x:data' type='result'/>".parse().unwrap();
|
||||
|
|
|
@ -43,6 +43,11 @@ mod tests {
|
|||
use chrono::{Datelike, Timelike};
|
||||
use std::error::Error as StdError;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(DateTime, 16);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let date: DateTime = "2002-09-10T23:08:25Z".parse().unwrap();
|
||||
|
|
|
@ -39,6 +39,11 @@ mod tests {
|
|||
use error::Error;
|
||||
use std::str::FromStr;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Delay, 112);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<delay xmlns='urn:xmpp:delay' from='capulet.com' stamp='2002-09-10T23:08:25Z'/>".parse().unwrap();
|
||||
|
|
12
src/disco.rs
12
src/disco.rs
|
@ -235,6 +235,18 @@ mod tests {
|
|||
use compare_elements::NamespaceAwareCompare;
|
||||
use std::str::FromStr;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Identity, 96);
|
||||
assert_size!(Feature, 24);
|
||||
assert_size!(DiscoInfoQuery, 24);
|
||||
assert_size!(DiscoInfoResult, 96);
|
||||
|
||||
assert_size!(Item, 120);
|
||||
assert_size!(DiscoItemsQuery, 24);
|
||||
assert_size!(DiscoItemsResult, 48);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<query xmlns='http://jabber.org/protocol/disco#info'><identity category='client' type='pc'/><feature var='http://jabber.org/protocol/disco#info'/></query>".parse().unwrap();
|
||||
|
|
|
@ -152,6 +152,11 @@ mod tests {
|
|||
use minidom::Element;
|
||||
use error::Error;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(ECaps2, 24);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_parse() {
|
||||
let elem: Element = "<c xmlns='urn:xmpp:caps'><hash xmlns='urn:xmpp:hashes:2' algo='sha-256'>K1Njy3HZBThlo4moOD5gBGhn0U0oK7/CbfLlIUDi6o4=</hash><hash xmlns='urn:xmpp:hashes:2' algo='sha3-256'>+sDTQqBmX6iG/X3zjt06fjZMBBqL/723knFIyRf0sg8=</hash></c>".parse().unwrap();
|
||||
|
|
|
@ -28,6 +28,11 @@ mod tests {
|
|||
use minidom::Element;
|
||||
use error::Error;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(ExplicitMessageEncryption, 48);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<encryption xmlns='urn:xmpp:eme:0' namespace='urn:xmpp:otr:0'/>".parse().unwrap();
|
||||
|
|
|
@ -30,6 +30,11 @@ mod tests {
|
|||
use minidom::Element;
|
||||
use error::Error;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Forwarded, 392);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<forwarded xmlns='urn:xmpp:forward:0'/>".parse().unwrap();
|
||||
|
|
|
@ -133,6 +133,12 @@ mod tests {
|
|||
use try_from::TryFrom;
|
||||
use minidom::Element;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Algo, 32);
|
||||
assert_size!(Hash, 56);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<hash xmlns='urn:xmpp:hashes:2' algo='sha-256'>2XarmwTlNxDAMkvymloX3S5+VbylNrJt/l5QyPa+YoU=</hash>".parse().unwrap();
|
||||
|
|
|
@ -76,6 +76,14 @@ mod tests {
|
|||
use error::Error;
|
||||
use std::error::Error as StdError;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Stanza, 1);
|
||||
assert_size!(Open, 32);
|
||||
assert_size!(Data, 56);
|
||||
assert_size!(Close, 24);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let sid = StreamId(String::from("coucou"));
|
||||
|
|
|
@ -96,6 +96,11 @@ mod tests {
|
|||
use super::*;
|
||||
use compare_elements::NamespaceAwareCompare;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Query, 152);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<query xmlns='jabber:iq:register'/>".parse().unwrap();
|
||||
|
|
|
@ -27,6 +27,11 @@ mod tests {
|
|||
use std::str::FromStr;
|
||||
use std::error::Error as StdError;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Idle, 16);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<idle xmlns='urn:xmpp:idle:1' since='2017-05-21T20:19:55+01:00'/>".parse().unwrap();
|
||||
|
|
|
@ -226,6 +226,12 @@ mod tests {
|
|||
use compare_elements::NamespaceAwareCompare;
|
||||
use disco::DiscoInfoQuery;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(IqType, 216);
|
||||
assert_size!(Iq, 384);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_require_type() {
|
||||
#[cfg(not(feature = "component"))]
|
||||
|
|
|
@ -533,6 +533,20 @@ impl From<Jingle> for Element {
|
|||
mod tests {
|
||||
use super::*;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Action, 1);
|
||||
assert_size!(Creator, 1);
|
||||
assert_size!(Senders, 1);
|
||||
assert_size!(Disposition, 1);
|
||||
assert_size!(ContentId, 24);
|
||||
assert_size!(Content, 344);
|
||||
assert_size!(Reason, 1);
|
||||
assert_size!(ReasonElement, 32);
|
||||
assert_size!(SessionId, 24);
|
||||
assert_size!(Jingle, 256);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<jingle xmlns='urn:xmpp:jingle:1' action='session-initiate' sid='coucou'/>".parse().unwrap();
|
||||
|
|
|
@ -348,6 +348,15 @@ mod tests {
|
|||
use hashes::Algo;
|
||||
use base64;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Range, 48);
|
||||
assert_size!(File, 184);
|
||||
assert_size!(Description, 184);
|
||||
assert_size!(Checksum, 216);
|
||||
assert_size!(Received, 32);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_description() {
|
||||
let elem: Element = r#"
|
||||
|
|
|
@ -29,6 +29,11 @@ mod tests {
|
|||
use error::Error;
|
||||
use std::error::Error as StdError;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Transport, 32);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<transport xmlns='urn:xmpp:jingle:transports:ibb:1' block-size='3' sid='coucou'/>".parse().unwrap();
|
||||
|
|
|
@ -121,6 +121,11 @@ impl From<JingleMI> for Element {
|
|||
mod tests {
|
||||
use super::*;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(JingleMI, 136);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<accept xmlns='urn:xmpp:jingle-message:0' id='coucou'/>".parse().unwrap();
|
||||
|
|
|
@ -277,6 +277,17 @@ mod tests {
|
|||
use std::str::FromStr;
|
||||
use compare_elements::NamespaceAwareCompare;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Type, 1);
|
||||
assert_size!(Mode, 1);
|
||||
assert_size!(CandidateId, 24);
|
||||
assert_size!(StreamId, 24);
|
||||
assert_size!(Candidate, 128);
|
||||
assert_size!(TransportPayload, 32);
|
||||
assert_size!(Transport, 88);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<transport xmlns='urn:xmpp:jingle:transports:s5b:1' sid='coucou'/>".parse().unwrap();
|
||||
|
|
|
@ -510,3 +510,9 @@ macro_rules! generate_element {
|
|||
}
|
||||
);
|
||||
}
|
||||
|
||||
macro_rules! assert_size (
|
||||
($t:ty, $sz:expr) => (
|
||||
assert_eq!(::std::mem::size_of::<$t>(), $sz);
|
||||
);
|
||||
);
|
||||
|
|
11
src/mam.rs
11
src/mam.rs
|
@ -191,6 +191,17 @@ mod tests {
|
|||
use super::*;
|
||||
use std::str::FromStr;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(QueryId, 24);
|
||||
assert_size!(Query, 232);
|
||||
assert_size!(Result_, 440);
|
||||
assert_size!(Complete, 1);
|
||||
assert_size!(Fin, 88);
|
||||
assert_size!(DefaultPrefs, 1);
|
||||
assert_size!(Prefs, 56);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_query() {
|
||||
let elem: Element = "<query xmlns='urn:xmpp:mam:2'/>".parse().unwrap();
|
||||
|
|
|
@ -51,6 +51,12 @@ mod tests {
|
|||
use data_forms::DataForm;
|
||||
use std::error::Error as StdError;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(URI, 48);
|
||||
assert_size!(MediaElement, 56);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<media xmlns='urn:xmpp:media-element'/>".parse().unwrap();
|
||||
|
|
|
@ -234,6 +234,15 @@ mod tests {
|
|||
use std::str::FromStr;
|
||||
use compare_elements::NamespaceAwareCompare;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(MessageType, 1);
|
||||
assert_size!(Body, 24);
|
||||
assert_size!(Subject, 24);
|
||||
assert_size!(Thread, 24);
|
||||
assert_size!(Message, 272);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
#[cfg(not(feature = "component"))]
|
||||
|
|
|
@ -25,6 +25,11 @@ mod tests {
|
|||
use minidom::Element;
|
||||
use error::Error;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Replace, 24);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<replace xmlns='urn:xmpp:message-correct:0' id='coucou'/>".parse().unwrap();
|
||||
|
|
|
@ -272,6 +272,12 @@ mod tests {
|
|||
use try_from::TryFrom;
|
||||
use minidom::Element;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(MoodEnum, 1);
|
||||
assert_size!(Text, 24);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<happy xmlns='http://jabber.org/protocol/mood'/>".parse().unwrap();
|
||||
|
|
|
@ -16,6 +16,11 @@ mod tests {
|
|||
use minidom::Element;
|
||||
use error::Error;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Nick, 24);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<nick xmlns='http://jabber.org/protocol/nick'>Link Mauve</nick>".parse().unwrap();
|
||||
|
|
|
@ -22,6 +22,11 @@ mod tests {
|
|||
use minidom::Element;
|
||||
use error::Error;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Ping, 0);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<ping xmlns='urn:xmpp:ping'/>".parse().unwrap();
|
||||
|
|
|
@ -323,6 +323,13 @@ mod tests {
|
|||
use super::*;
|
||||
use compare_elements::NamespaceAwareCompare;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Show, 1);
|
||||
assert_size!(Type, 1);
|
||||
assert_size!(Presence, 224);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
#[cfg(not(feature = "component"))]
|
||||
|
|
|
@ -33,6 +33,12 @@ mod tests {
|
|||
use minidom::Element;
|
||||
use ns;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Request, 0);
|
||||
assert_size!(Received, 24);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<request xmlns='urn:xmpp:receipts'/>".parse().unwrap();
|
||||
|
|
|
@ -85,6 +85,14 @@ mod tests {
|
|||
use std::str::FromStr;
|
||||
use compare_elements::NamespaceAwareCompare;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Group, 24);
|
||||
assert_size!(Subscription, 1);
|
||||
assert_size!(Item, 128);
|
||||
assert_size!(Roster, 48);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_get() {
|
||||
let elem: Element = "<query xmlns='jabber:iq:roster'/>".parse().unwrap();
|
||||
|
|
|
@ -158,6 +158,12 @@ mod tests {
|
|||
use super::*;
|
||||
use compare_elements::NamespaceAwareCompare;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(SetQuery, 80);
|
||||
assert_size!(SetResult, 80);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<set xmlns='http://jabber.org/protocol/rsm'/>".parse().unwrap();
|
||||
|
|
12
src/sasl.rs
12
src/sasl.rs
|
@ -215,6 +215,18 @@ mod tests {
|
|||
use try_from::TryFrom;
|
||||
use minidom::Element;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Mechanism, 1);
|
||||
assert_size!(Auth, 32);
|
||||
assert_size!(Challenge, 24);
|
||||
assert_size!(Response, 24);
|
||||
assert_size!(Abort, 0);
|
||||
assert_size!(Success, 24);
|
||||
assert_size!(DefinedCondition, 1);
|
||||
assert_size!(Failure, 32);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'/>".parse().unwrap();
|
||||
|
|
14
src/sm.rs
14
src/sm.rs
|
@ -144,6 +144,20 @@ mod tests {
|
|||
use try_from::TryFrom;
|
||||
use minidom::Element;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(A, 4);
|
||||
assert_size!(ResumeAttr, 1);
|
||||
assert_size!(Enable, 12);
|
||||
assert_size!(StreamId, 24);
|
||||
assert_size!(Enabled, 64);
|
||||
assert_size!(Failed, 12);
|
||||
assert_size!(R, 0);
|
||||
assert_size!(Resume, 32);
|
||||
assert_size!(Resumed, 32);
|
||||
assert_size!(StreamManagement, 0);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn a() {
|
||||
let elem: Element = "<a xmlns='urn:xmpp:sm:3' h='5'".parse().unwrap();
|
||||
|
|
|
@ -289,6 +289,13 @@ impl From<StanzaError> for Element {
|
|||
mod tests {
|
||||
use super::*;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(ErrorType, 1);
|
||||
assert_size!(DefinedCondition, 1);
|
||||
assert_size!(StanzaError, 208);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
#[cfg(not(feature = "component"))]
|
||||
|
|
|
@ -42,6 +42,12 @@ mod tests {
|
|||
use error::Error;
|
||||
use std::str::FromStr;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(StanzaId, 96);
|
||||
assert_size!(OriginId, 24);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<stanza-id xmlns='urn:xmpp:sid:0' id='coucou' by='coucou@coucou'/>".parse().unwrap();
|
||||
|
|
|
@ -76,6 +76,11 @@ mod tests {
|
|||
use try_from::TryFrom;
|
||||
use minidom::Element;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Stream, 216);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' xml:lang='en' version='1.0' id='abc' from='some-server.example'/>".parse().unwrap();
|
||||
|
|
|
@ -43,6 +43,12 @@ mod tests {
|
|||
use minidom::Element;
|
||||
use compare_elements::NamespaceAwareCompare;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(VersionQuery, 0);
|
||||
assert_size!(VersionResult, 72);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn simple() {
|
||||
let elem: Element = "<query xmlns='jabber:iq:version'><name>xmpp-rs</name><version>0.3.0</version></query>".parse().unwrap();
|
||||
|
|
|
@ -75,6 +75,11 @@ mod tests {
|
|||
use try_from::TryFrom;
|
||||
use minidom::Element;
|
||||
|
||||
#[test]
|
||||
fn test_size() {
|
||||
assert_size!(Open, 216);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_simple() {
|
||||
let elem: Element = "<open xmlns='urn:ietf:params:xml:ns:xmpp-framing'/>".parse().unwrap();
|
||||
|
|
Loading…
Reference in a new issue