'Test a saved private key.'

def test_save_priv_key(self):

    key_name = 'save_private'
    (tp_test, created_key) = self._get_mock_kp_for_create(key_name, priv_saved=True)
    self.patchobject(self.fake_keypairs, 'get', return_value=created_key)
    scheduler.TaskRunner(tp_test.create)()
    self.assertEqual('private    key    for    save_private', tp_test.FnGetAtt('private_key'))
    self.assertEqual('generated    test    public    key', tp_test.FnGetAtt('public_key'))
    self.assertEqual((tp_test.CREATE, tp_test.COMPLETE), tp_test.state)
    self.assertEqual(tp_test.resource_id, created_key.name)
