Add tests for #destroy and #getPrivateKey