Fix failing unit test for key pair creation.