Use glanceclient for functional tests
With the 2.36 microversion in nova the images proxy API is deprecated and returns a 404. This change makes the functional tests use glanceclient directly for listing images. Change-Id: If02bc97a10f1551a707e8e1cdb548fc27ef22ce1
This commit is contained in:
@@ -16,6 +16,7 @@ import uuid
|
||||
|
||||
from cinderclient.v2 import client as cinderclient
|
||||
import fixtures
|
||||
from glanceclient import client as glanceclient
|
||||
from keystoneauth1.exceptions import discovery as discovery_exc
|
||||
from keystoneauth1 import identity
|
||||
from keystoneauth1 import session as ksession
|
||||
@@ -208,9 +209,11 @@ class ClientTestBase(testtools.TestCase):
|
||||
|
||||
self.client = novaclient.client.Client(version, session=session)
|
||||
|
||||
self.glance = glanceclient.Client('2', session=session)
|
||||
|
||||
# pick some reasonable flavor / image combo
|
||||
self.flavor = pick_flavor(self.client.flavors.list())
|
||||
self.image = pick_image(self.client.images.list())
|
||||
self.image = pick_image(self.glance.images.list())
|
||||
self.network = pick_network(self.client.networks.list())
|
||||
|
||||
# create a CLI client in case we'd like to do CLI
|
||||
|
@@ -10,6 +10,7 @@ keyring>=5.5.1 # MIT/PSF
|
||||
mock>=2.0 # BSD
|
||||
python-keystoneclient!=2.1.0,>=2.0.0 # Apache-2.0
|
||||
python-cinderclient!=1.7.0,!=1.7.1,>=1.6.0 # Apache-2.0
|
||||
python-glanceclient>=2.0.0 # Apache-2.0
|
||||
requests-mock>=1.0 # Apache-2.0
|
||||
sphinx!=1.3b1,<1.3,>=1.2.1 # BSD
|
||||
os-client-config!=1.19.0,>=1.13.1 # Apache-2.0
|
||||
|
Reference in New Issue
Block a user