Remove neutron-fwaas-dashboard package for >= V
neutron-fwaas project is retired from Victoria release. This patch removes installing neutron-fwaas-dashboard package from Victoria release onwards. Closes-Bug: 1934129 Change-Id: Id2c8695274bb3438612ee44bb922766a6bddf900
This commit is contained in:
parent
dbc4077ba5
commit
4355ea2d6b
|
@ -509,6 +509,8 @@ def determine_packages():
|
|||
packages = set(packages)
|
||||
if release >= 'train':
|
||||
packages.remove('python3-neutron-lbaas-dashboard')
|
||||
if release >= 'victoria':
|
||||
packages.remove('python3-neutron-fwaas-dashboard')
|
||||
# NOTE(ajkavanagh) - don't reinstall packages (e.g. on upgrade) that
|
||||
# plugins have already indicated should not be installed as they clash with
|
||||
# the plugin. Do add in any packages that the plugins want. Note that
|
||||
|
@ -566,6 +568,8 @@ def determine_purge_packages():
|
|||
])
|
||||
if release >= 'train':
|
||||
pkgs.append('python3-neutron-lbaas-dashboard')
|
||||
if release >= 'victoria':
|
||||
pkgs.append('python3-neutron-fwaas-dashboard')
|
||||
# NOTE(ajkavanagh) also ensure that associated plugins can purge on upgrade
|
||||
return list(set(pkgs)
|
||||
.union(set(determine_purge_packages_dashboard_plugin())))
|
||||
|
|
|
@ -86,6 +86,21 @@ class TestHorizonUtils(CharmTestCase):
|
|||
horizon_utils.PY3_PACKAGES)
|
||||
)
|
||||
|
||||
def test_determine_packages_victoria(self):
|
||||
horizon_utils.os_release.return_value = 'victoria'
|
||||
verify_pkgs = [
|
||||
p for p in horizon_utils.BASE_PACKAGES
|
||||
if not p.startswith('python-')
|
||||
] + horizon_utils.PY3_PACKAGES
|
||||
verify_pkgs.append('python3-mysqldb')
|
||||
verify_pkgs.remove('python3-neutron-lbaas-dashboard')
|
||||
verify_pkgs.remove('python3-neutron-fwaas-dashboard')
|
||||
|
||||
self.assertEqual(
|
||||
sorted(horizon_utils.determine_packages()),
|
||||
sorted(verify_pkgs)
|
||||
)
|
||||
|
||||
def test_determine_purge_packages(self):
|
||||
'Ensure no packages are identified for purge prior to rocky'
|
||||
horizon_utils.os_release.return_value = 'queens'
|
||||
|
@ -109,6 +124,25 @@ class TestHorizonUtils(CharmTestCase):
|
|||
sorted(horizon_utils.determine_purge_packages()),
|
||||
sorted(verify_pkgs))
|
||||
|
||||
def test_determine_purge_packages_victoria(self):
|
||||
'Ensure python packages are identified for purge at victoria'
|
||||
horizon_utils.relation_ids.return_value = []
|
||||
horizon_utils.os_release.return_value = 'victoria'
|
||||
verify_pkgs = (
|
||||
[p for p in horizon_utils.BASE_PACKAGES
|
||||
if p.startswith('python-')] +
|
||||
['python-django-horizon',
|
||||
'python-django-openstack-auth',
|
||||
'python-pymysql',
|
||||
'python-neutron-lbaas-dashboard',
|
||||
'python-designate-dashboard',
|
||||
'python-heat-dashboard',
|
||||
'python3-neutron-lbaas-dashboard',
|
||||
'python3-neutron-fwaas-dashboard'])
|
||||
self.assertEqual(
|
||||
sorted(horizon_utils.determine_purge_packages()),
|
||||
sorted(verify_pkgs))
|
||||
|
||||
def _patch_for_dashboard_plugin_packages(self):
|
||||
|
||||
def relation_ids_side_effect(rname):
|
||||
|
|
Loading…
Reference in New Issue