From e9088d09328793495aba260a05d6161f92aae4cd Mon Sep 17 00:00:00 2001 From: Armando Migliaccio Date: Fri, 11 Mar 2016 08:00:34 -0800 Subject: [PATCH] Remove test_external_network_visibility This test was left behind according to plan laid out in patch [1]. Make its removal conditional to the Tempest sync-up patch. [1] https://review.openstack.org/#/c/280427/ Related-bug: 1553595 Related-bug: 1552960 (cherry-picked from commit cc863e07156e3cfe020c5acfcd9875daff477de6) Change-Id: Ia85e7d03c32b5e2db901aed2c13bafe83896be0b Depends-on: I0219e17d2ec70939039344826d35cb533b3ce065 --- neutron/tests/api/test_networks.py | 28 ---------------------------- 1 file changed, 28 deletions(-) diff --git a/neutron/tests/api/test_networks.py b/neutron/tests/api/test_networks.py index 37bd47a683a..3f409e5f631 100644 --- a/neutron/tests/api/test_networks.py +++ b/neutron/tests/api/test_networks.py @@ -13,8 +13,6 @@ # License for the specific language governing permissions and limitations # under the License. -import itertools - from tempest import test from neutron.tests.api import base @@ -97,29 +95,3 @@ class NetworksTestJSON(base.BaseNetworkTest): self.assertNotEmpty(networks, "Network list returned is empty") for network in networks: self.assertEqual(sorted(network.keys()), sorted(fields)) - - @test.attr(type='smoke') - @test.idempotent_id('af774677-42a9-4e4b-bb58-16fe6a5bc1ec') - def test_external_network_visibility(self): - """Verifies user can see external networks but not subnets.""" - body = self.client.list_networks(**{'router:external': True}) - # shared external networks are excluded since their subnets are - # visible - networks = [network['id'] for network in body['networks'] - if not network['shared']] - self.assertNotEmpty(networks, "No external networks found") - - nonexternal = [net for net in body['networks'] if - not net['router:external']] - self.assertEmpty(nonexternal, "Found non-external networks" - " in filtered list (%s)." % nonexternal) - self.assertIn(CONF.network.public_network_id, networks) - - subnets_iter = (network['subnets'] for network in body['networks']) - # subnets_iter is a list (iterator) of lists. This flattens it to a - # list of UUIDs - public_subnets_iter = itertools.chain(*subnets_iter) - body = self.client.list_subnets() - subnets = [sub['id'] for sub in body['subnets'] - if sub['id'] in public_subnets_iter] - self.assertEmpty(subnets, "Public subnets visible")