'When the server verifies and the client presents an invalid certificate
for that verification by passing it to
L{sslverify.optionsForClientTLS}, the connection cannot be established
with an SSL error.'

def test_clientPresentsBadCertificate(self):

    (cProto, sProto, pump) = self.serviceIdentitySetup(u'valid.example.com', u'valid.example.com', validCertificate=True, serverVerifies=True, validClientCertificate=False, clientPresentsCertificate=True)
    self.assertEqual(cProto.wrappedProtocol.data, '')
    cErr = cProto.wrappedProtocol.lostReason.value
    sErr = sProto.wrappedProtocol.lostReason.value
    self.assertIsInstance(cErr, SSL.Error)
    self.assertIsInstance(sErr, SSL.Error)
