Now Y2Storage::GuidedProposal is also used by D-Installer and we don't want to follow the YaST approach for reusing stuff. Since D-Installer represents a new playground, we don't need to play by the old rules and expectations.
Solution
Introduce a new setting into Y2Storage::ProposalSettings that will be used only by D-Installer (for the time being) and that will inhibit the mechanism to reuse existing LVM volume groups.
Testing
Added unit tests. Backwards compatibility ensured because all the previous tests keep working with no modification.
Note about the version
Version of the package not bumped because we are not in a hurry to submit this to Factory and @jreidinger is already working on another change for yast-storage-ng.
Coverage increased (+0.0002%) to 97.754% when pulling 79a4eff436b8e8c4797a0deb3c927b11888c85fd on ancorgs:lvm_vg_reuse into 64989e48e7d8052b4cf6818ee556099ec795264b on yast:master.
Problem
For historical reasons, YaST tries to reuse existing LVM volume groups when making a proposal.
That behavior can be very confusing in many situations. Some of the associated problems and historical factors are described here: https://trello.com/c/Ib7QC298/19-proposal-strategy-for-reusing-stuff-in-proposal-bug1091998-and-others
Now
Y2Storage::GuidedProposal
is also used by D-Installer and we don't want to follow the YaST approach for reusing stuff. Since D-Installer represents a new playground, we don't need to play by the old rules and expectations.Solution
Introduce a new setting into
Y2Storage::ProposalSettings
that will be used only by D-Installer (for the time being) and that will inhibit the mechanism to reuse existing LVM volume groups.Testing
Added unit tests. Backwards compatibility ensured because all the previous tests keep working with no modification.
Note about the version
Version of the package not bumped because we are not in a hurry to submit this to Factory and @jreidinger is already working on another change for yast-storage-ng.