'Test that an invalid XML input returns an L{xmlrpc.Fault}.'

def test_errorXMLContent(self):

    agent = client.Agent(reactor)
    d = agent.request(uri=networkString(('http://127.0.0.1:%d/' % (self.port,))), method='POST', bodyProducer=client.FileBodyProducer(BytesIO('foo')))
    d.addCallback(client.readBody)
    def cb(result):
        self.assertRaises(xmlrpc.Fault, xmlrpclib.loads, result)
    d.addCallback(cb)
    return d
