stanzaBuilder.addAttribute("id", "1");
stanzaBuilder.addAttribute("type", "get");
stanzaBuilder.startInnerElement("getRequest").endInnerElement();
TestIQHandler iqHandler = new TestIQHandler();
ResponseStanzaContainer responseStanzaContainer = iqHandler.execute(stanzaBuilder.build(), sessionContext.getServerRuntimeContext(), true, sessionContext, null);
IQStanza incomingStanza = iqHandler.getIncomingStanza();
XMPPCoreStanzaVerifier verifier = incomingStanza.getCoreVerifier();
assertTrue("iq", verifier.nameEquals("iq"));
assertTrue("iq-id", verifier.attributeEquals("id", "1"));
assertTrue("iq-type-get", verifier.attributeEquals("type", "get"));
// response is "result"
Stanza responseStanza = responseStanzaContainer.getResponseStanza();
XMLElementVerifier responseVerifier = responseStanza.getVerifier();
assertTrue("iq", responseVerifier.nameEquals("iq"));
assertTrue("iq-id", responseVerifier.attributeEquals("id", "1"));
assertTrue("iq-type-result", responseVerifier.attributeEquals("type", "result"));
}