':py:meth:`PKeyType.generate_key` generates an RSA key when passed
:py:data:`TYPE_RSA` as a type and a reasonable number of bits.'

def test_rsaGeneration(self):

    bits = 128
    key = PKey()
    key.generate_key(TYPE_RSA, bits)
    self.assertEqual(key.type(), TYPE_RSA)
    self.assertEqual(key.bits(), bits)
    self.assertTrue(key.check())
