'Test using a dynamic info handler for all requests.'

def testDynamicInfoGlobal(self):

    self.stream_start(mode='component', jid='tester.localhost', plugins=['xep_0030'])
    def dynamic_global(jid, node, ifrom, iq):
        result = self.xmpp['xep_0030'].stanza.DiscoInfo()
        result['node'] = node
        result.add_identity('component', 'generic', name='Dynamic    Info')
        return result
    self.xmpp['xep_0030'].set_node_handler('get_info', handler=dynamic_global)
    self.recv('\n                                        <iq    type="get"    id="test"\n                                                        to="user@tester.localhost"\n                                                        from="tester@localhost">\n                                                <query    xmlns="http://jabber.org/protocol/disco#info"\n                                                                            node="testing"    />\n                                        </iq>\n                                ')
    self.send('\n                                        <iq    type="result"    id="test"\n                                                        to="tester@localhost"\n                                                        from="user@tester.localhost">\n                                                <query    xmlns="http://jabber.org/protocol/disco#info"\n                                                                            node="testing">\n                                                        <identity    category="component"\n                                                                                                type="generic"\n                                                                                                name="Dynamic    Info"    />\n                                                </query>\n                                        </iq>\n                                ')
