mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-30 22:31:25 -07:00
parted module not idempotent for esp flag and name (#40547)
* parted module not idempotent for esp flag and name Fixes #40452 Currently the parted module doesn't take into account names with spaces in them which leads to non-idempotent transactions on the state of the system because the name comparison will never succeed. Also, when the esp flag is set, parted infers the boot flag and the parted module did not previously account for this. This lead to non-idempotent transactions as well. Signed-off-by: Adam Miller <admiller@redhat.com> * fix unit tests, expected command changed in the patch Signed-off-by: Adam Miller <admiller@redhat.com>
This commit is contained in:
parent
67e0df81c1
commit
bc7ff83cd9
2 changed files with 10 additions and 2 deletions
|
@ -237,4 +237,4 @@ class TestParted(ModuleTestCase):
|
|||
'_ansible_check_mode': True,
|
||||
})
|
||||
with patch('ansible.modules.system.parted.get_device_info', return_value=parted_dict2):
|
||||
self.execute_module(changed=True, script='unit KiB mklabel gpt mkpart primary 0% 100% unit KiB name 1 lvmpartition set 1 lvm on')
|
||||
self.execute_module(changed=True, script='unit KiB mklabel gpt mkpart primary 0% 100% unit KiB name 1 \'"lvmpartition"\' set 1 lvm on')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue