tests: Remove duplicate FakeImagev1Client
I guess this was defined to avoid a circular import. There are easier ways to do this. Change-Id: Iab215a53691298413ea9d10def792008ab9edbce Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
This commit is contained in:
parent
e2940eea18
commit
d7f431be50
@ -23,12 +23,6 @@ from openstackclient.tests.unit.identity.v2_0 import fakes as identity_fakes
|
|||||||
from openstackclient.tests.unit import utils
|
from openstackclient.tests.unit import utils
|
||||||
|
|
||||||
|
|
||||||
class FakeImagev1Client:
|
|
||||||
|
|
||||||
def __init__(self, **kwargs):
|
|
||||||
self.images = mock.Mock()
|
|
||||||
|
|
||||||
|
|
||||||
class FakeVolumev1Client:
|
class FakeVolumev1Client:
|
||||||
|
|
||||||
def __init__(self, **kwargs):
|
def __init__(self, **kwargs):
|
||||||
@ -72,7 +66,10 @@ class TestVolumev1(utils.TestCommand):
|
|||||||
token=fakes.AUTH_TOKEN,
|
token=fakes.AUTH_TOKEN,
|
||||||
)
|
)
|
||||||
|
|
||||||
self.app.client_manager.image = FakeImagev1Client(
|
# avoid circular imports
|
||||||
|
from openstackclient.tests.unit.image.v1 import fakes as image_fakes
|
||||||
|
|
||||||
|
self.app.client_manager.image = image_fakes.FakeImagev1Client(
|
||||||
endpoint=fakes.AUTH_URL,
|
endpoint=fakes.AUTH_URL,
|
||||||
token=fakes.AUTH_TOKEN,
|
token=fakes.AUTH_TOKEN,
|
||||||
)
|
)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user