" <feature var='jabber:iq:version'/>\n" +
" </query>\n" +
"</iq>";
IQ iq = unmarshal(xml, IQ.class);
InfoDiscovery serviceDiscovery = iq.getExtension(InfoDiscovery.class);
Assert.assertNotNull(serviceDiscovery);
Assert.assertEquals(serviceDiscovery.getIdentities().size(), 2);
Assert.assertEquals(serviceDiscovery.getFeatures().size(), 7);
Identity identity1 = new Identity("conference", "text", "Play-Specific Chatrooms");
Identity identity2 = new Identity("directory", "chatroom", "Play-Specific Chatrooms");
Assert.assertTrue(serviceDiscovery.getIdentities().contains(identity1));
Assert.assertTrue(serviceDiscovery.getIdentities().contains(identity2));
Assert.assertTrue(serviceDiscovery.getFeatures().contains(new Feature("http://jabber.org/protocol/disco#info")));
Assert.assertTrue(serviceDiscovery.getFeatures().contains(new Feature("http://jabber.org/protocol/disco#items")));
Assert.assertTrue(serviceDiscovery.getFeatures().contains(new Feature("http://jabber.org/protocol/muc")));
Assert.assertTrue(serviceDiscovery.getFeatures().contains(new Feature("jabber:iq:register")));
Assert.assertTrue(serviceDiscovery.getFeatures().contains(new Feature("jabber:iq:search")));
Assert.assertTrue(serviceDiscovery.getFeatures().contains(new Feature("jabber:iq:time")));
Assert.assertTrue(serviceDiscovery.getFeatures().contains(new Feature("jabber:iq:version")));
}