Add newton->ocata undercloud upgrades to unsupported list

Change-Id: I4c8f389978717848e755f12856dd454d605c9137
This commit is contained in:
John Trowbridge 2018-05-17 09:59:29 -04:00 committed by Ronelle Landy
parent 8d4adf4233
commit f76569c23b
2 changed files with 14 additions and 0 deletions

View File

@ -79,6 +79,10 @@ def compose_releases_dictionary(stable_release, featureset):
stable_release == RELEASES[0]:
raise RuntimeError("Cannot upgrade to {}".format(RELEASES[0]))
if featureset.get('undercloud_upgrade') and stable_release == 'ocata':
raise RuntimeError("Undercloud upgrades are not supported from "
"newton to ocata")
if featureset.get('overcloud_upgrade') and \
featureset.get('undercloud_upgrade'):
raise RuntimeError("This tool currently only supports upgrading the "

View File

@ -25,6 +25,16 @@ def test_only_mixed_overcloud_upgrades_are_supported():
compose_releases_dictionary(stable_release, featureset)
def test_undercloud_upgrades_from_newton_to_ocata_are_unsupported():
featureset = {
'undercloud_upgrade': True,
}
stable_release = 'ocata'
with pytest.raises(RuntimeError):
compose_releases_dictionary(stable_release, featureset)
@pytest.mark.parametrize('upgrade_type',
['ffu_overcloud_upgrade', 'overcloud_upgrade'])
def test_overcloud_upgrades_has_to_be_mixed(upgrade_type):