'The quiescentCallback is called before the request C{Deferred} fires,
in cases where the response has no body.'

def test_quiescentCallbackCalledEmptyResponse(self):

    quiescentResult = []
    def callback(p):
        self.assertEqual(p, protocol)
        self.assertEqual(p.state, u'QUIESCENT')
        quiescentResult.append(p)
    transport = StringTransport()
    protocol = HTTP11ClientProtocol(callback)
    protocol.makeConnection(transport)
    requestDeferred = protocol.request(Request('GET', '/', _boringHeaders, None, persistent=True))
    requestDeferred.addCallback(quiescentResult.append)
    protocol.dataReceived('HTTP/1.1    200    OK\r\nContent-length:    0\r\n\r\n')
    self.assertEqual(len(quiescentResult), 2)
    self.assertIdentical(quiescentResult[0], protocol)
    self.assertIsInstance(quiescentResult[1], Response)
