Updated openstack/openstack
Project: openstack/cinder  00da815882ed3cc506d2e6dbd7221b6668a6fa86

HP 3PAR: Allow retype when the old snapshot CPG (3PAR pool) is None

A common provisioning group (CPG) is a virtual pool of logical disks.
A volume is stored in a CPG. The volume's snapshots may be stored in
the same CPG or in a separate CPG. In 3PAR this is the "snapCPG".

Before the 3PAR driver supported "manage", the snapCPG was never None in
OpenStack because when we create volumes, we explicitly default snapCPG
to match the volume CPG unless otherwise specified. So, the original
retype pre-checks raised an exception if this unexpected case occurred
and a unit test was provided for that exception.

Now that we support manage_existing(), it should be a valid use case
to manage an existing volume created outside of OpenStack with a snapCPG
set to None. Unfortunately, when we applied volume-type settings to this
volume we would hit that old exception.

That exception has been removed. 

Removing it required the following changes:

1. When retype pre-checks validate the domain of the new snapCPG, it
   will not use the optional old snapCPG. Instead it will compare the
   new snapCPG domain with the old volume CPG domain. This satisfies
   the requirement that domains cannot be mixed and avoids the need
   to have an old snapCPG setting.

2. Remove the no longer used old_snap_cpg parameter and remove the
   code that raised an exception "if not old_snap_cpg".

3. Remove the unit test that was just to test that obsolete exception.

4. Adjust the exiting test_retype_across_snap_cpg_domains to
   verify that a snapCPG domain that does not match the volume
   CPG domain will still raise Invalid3PARDomain

Change-Id: Icd2c66898ef64f81116df102f5529a8da30c14d5
Closes-Bug: 1368927