mirror of
https://opendev.org/openstack/python-openstackclient.git
synced 2026-01-17 07:20:45 +00:00
Functional tests: Identity v2 and DevStack
DevStack master (as of 01May2017) no longer sets up an Identity v2 admin endpoint, so we need to skip those tests going forward and cover them via a specific leagacy job. This does the detect-and-skip. Change-Id: Ib9ab32b6bc84ec7d13508094ad6f83995d8d7bc1
This commit is contained in:
parent
1b9cf82b42
commit
983cccb662
1 changed files with 17 additions and 6 deletions
|
|
@ -13,6 +13,7 @@
|
|||
import os
|
||||
|
||||
from tempest.lib.common.utils import data_utils
|
||||
from tempest.lib import exceptions as tempest_exceptions
|
||||
|
||||
from openstackclient.tests.functional import base
|
||||
|
||||
|
|
@ -49,12 +50,22 @@ class IdentityTests(base.TestCase):
|
|||
# create dummy project
|
||||
cls.project_name = data_utils.rand_name('TestProject')
|
||||
cls.project_description = data_utils.rand_name('description')
|
||||
cls.openstack(
|
||||
'project create '
|
||||
'--description %(description)s '
|
||||
'--enable '
|
||||
'%(name)s' % {'description': cls.project_description,
|
||||
'name': cls.project_name})
|
||||
try:
|
||||
cls.openstack(
|
||||
'project create '
|
||||
'--description %(description)s '
|
||||
'--enable '
|
||||
'%(name)s' % {
|
||||
'description': cls.project_description,
|
||||
'name': cls.project_name,
|
||||
}
|
||||
)
|
||||
except tempest_exceptions.CommandFailed:
|
||||
# Good chance this is due to Identity v2 admin not being enabled
|
||||
# TODO(dtroyer): Actually determine if Identity v2 admin is
|
||||
# enabled in the target cloud. Tuens out OSC
|
||||
# doesn't make this easy as it should (yet).
|
||||
raise cls.skipException('No Identity v2 admin endpoint?')
|
||||
|
||||
@classmethod
|
||||
def tearDownClass(cls):
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue