'If a request failed due to the operation being cancelled,
C{_shouldRetry} returns C{False} to indicate the request should not be
retried.'

def test_dontRetryIfFailedDueToCancel(self):

    pool = client.HTTPConnectionPool(None)
    connection = client._RetryingHTTP11ClientProtocol(None, pool)
    exception = ResponseNeverReceived([Failure(defer.CancelledError())])
    self.assertFalse(connection._shouldRetry('GET', exception, None))
