Merge "[envs] Remove credentials base"

This commit is contained in:
Zuul 2018-01-19 14:19:25 +00:00 committed by Gerrit Code Review
commit 6ec92599ca
3 changed files with 6 additions and 6 deletions

View File

@ -15,14 +15,12 @@
from rally.common import logging
from rally import consts
from rally.deployment import credential
from rally.plugins.openstack import osclients
LOG = logging.getLogger(__file__)
@credential.configure("openstack")
class OpenStackCredential(credential.Credential):
class OpenStackCredential(object):
"""Credential for OpenStack."""
def __init__(self, auth_url, username, password, tenant_name=None,

View File

@ -173,3 +173,6 @@ class OpenStack(platform.Platform):
"services": osclients.Clients(active_user).list_services()
}
}
def _get_validation_context(self):
return {"users@openstack": {}}

View File

@ -16,7 +16,7 @@
import mock
from rally import consts
from rally.deployment import credential
from rally.plugins.openstack import credential
from tests.unit import test
@ -24,8 +24,7 @@ class OpenStackCredentialTestCase(test.TestCase):
def setUp(self):
super(OpenStackCredentialTestCase, self).setUp()
cred_cls = credential.get("openstack")
self.credential = cred_cls(
self.credential = credential.OpenStackCredential(
"foo_url", "foo_user", "foo_password",
tenant_name="foo_tenant",
permission=consts.EndpointPermission.ADMIN)