tests: Remove FakeNetworkV2Client
This no longer makes any sense since all network calls uses the SDK proxy API now. Change-Id: I0d57d7561b697270b24acd7b8ff62db73a83f49a Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
This commit is contained in:
parent
601d9717c2
commit
84dd5b0018
openstackclient/tests/unit
@ -1121,10 +1121,7 @@ class TestQuotaShow(TestQuota):
|
||||
'network': fake_network_endpoint
|
||||
}
|
||||
|
||||
self.app.client_manager.network = network_fakes.FakeNetworkV2Client(
|
||||
endpoint=fakes.AUTH_URL,
|
||||
token=fakes.AUTH_TOKEN,
|
||||
)
|
||||
self.app.client_manager.network = mock.Mock()
|
||||
self.network = self.app.client_manager.network
|
||||
self.network.get_quota = mock.Mock(
|
||||
return_value=network_fakes.QUOTA,
|
||||
|
@ -39,7 +39,6 @@ from openstackclient.api import compute_v2
|
||||
from openstackclient.tests.unit import fakes
|
||||
from openstackclient.tests.unit.identity.v2_0 import fakes as identity_fakes
|
||||
from openstackclient.tests.unit.image.v2 import fakes as image_fakes
|
||||
from openstackclient.tests.unit.network.v2 import fakes as network_fakes
|
||||
from openstackclient.tests.unit import utils
|
||||
from openstackclient.tests.unit.volume.v2 import fakes as volume_fakes
|
||||
|
||||
@ -150,7 +149,7 @@ class FakeComputev2Client(object):
|
||||
|
||||
class TestComputev2(utils.TestCommand):
|
||||
def setUp(self):
|
||||
super(TestComputev2, self).setUp()
|
||||
super().setUp()
|
||||
|
||||
self.app.client_manager.compute = FakeComputev2Client(
|
||||
endpoint=fakes.AUTH_URL,
|
||||
@ -172,10 +171,7 @@ class TestComputev2(utils.TestCommand):
|
||||
token=fakes.AUTH_TOKEN,
|
||||
)
|
||||
|
||||
self.app.client_manager.network = network_fakes.FakeNetworkV2Client(
|
||||
endpoint=fakes.AUTH_URL,
|
||||
token=fakes.AUTH_TOKEN,
|
||||
)
|
||||
self.app.client_manager.network = mock.Mock()
|
||||
|
||||
self.app.client_manager.volume = volume_fakes.FakeVolumeClient(
|
||||
endpoint=fakes.AUTH_URL,
|
||||
|
@ -93,13 +93,6 @@ VALID_DSCP_MARKS = [
|
||||
]
|
||||
|
||||
|
||||
class FakeNetworkV2Client(object):
|
||||
def __init__(self, **kwargs):
|
||||
self.session = mock.Mock()
|
||||
self.extensions = mock.Mock()
|
||||
self.extensions.resource_class = fakes.FakeResource(None, {})
|
||||
|
||||
|
||||
class TestNetworkV2(utils.TestCommand):
|
||||
def setUp(self):
|
||||
super().setUp()
|
||||
|
Loading…
x
Reference in New Issue
Block a user