Tempest: Fixing L3 agent hosting router for DVR setup

The tests for L3 agent hosting routers were failing in DVR setup
because the code was trying to add router to l3 agent when it was
already there.

Closes-bug: #1590049

Change-Id: I0087ad6f6df662579d557ab790de64e04ff22943
This commit is contained in:
Genadi Chereshnya 2017-01-17 11:06:42 +02:00 committed by Ihar Hrachyshka
parent d28a33a898
commit 08d29e3c90
1 changed files with 0 additions and 15 deletions

View File

@ -64,21 +64,6 @@ class L3AgentSchedulerTestJSON(base.BaseAdminNetworkTest):
msg = "L3 Agent Scheduler enabled in conf, but L3 Agent not found"
raise exceptions.InvalidConfiguration(msg)
cls.router = cls.create_router(data_utils.rand_name('router'))
# NOTE(armax): If DVR is an available extension, and the created router
# is indeed a distributed one, more resources need to be provisioned
# in order to bind the router to the L3 agent.
# That said, let's preserve the existing test logic, where the extra
# query and setup steps are only required if the extension is available
# and only if the router's default type is distributed.
if test.is_extension_enabled('dvr', 'network'):
is_dvr_router = cls.admin_client.show_router(
cls.router['id'])['router'].get('distributed', False)
if is_dvr_router:
cls.network = cls.create_network()
cls.create_subnet(cls.network)
cls.port = cls.create_port(cls.network)
cls.client.add_router_interface_with_port_id(
cls.router['id'], cls.port['id'])
@decorators.idempotent_id('b7ce6e89-e837-4ded-9b78-9ed3c9c6a45a')
def test_list_routers_on_l3_agent(self):