mirror of
https://github.com/containers/ansible-podman-collections.git
synced 2026-02-04 07:11:49 +00:00
Fix uppercase labels idempotency issue (#230)
When we lower cases for all keys, but leave it original case for all values, we need to do the same with input labels. Add test. Fix #227
This commit is contained in:
parent
f41c63815f
commit
607c120f94
2 changed files with 7 additions and 3 deletions
|
|
@ -873,7 +873,7 @@ class PodmanContainerDiff:
|
|||
after = self.image_info.get('labels') or {}
|
||||
if self.params['label']:
|
||||
after.update({
|
||||
str(k).lower(): str(v).lower()
|
||||
str(k).lower(): str(v)
|
||||
for k, v in self.params['label'].items()
|
||||
})
|
||||
return self._diff_update_and_compare('label', before, after)
|
||||
|
|
|
|||
|
|
@ -51,7 +51,9 @@
|
|||
state: present
|
||||
label:
|
||||
haha: kukuku
|
||||
llala: wiwiwiw
|
||||
LLALA: WIWIWIW
|
||||
OEIWIOP: eufslsa
|
||||
ieui4: KDJSL4D
|
||||
command: 1h
|
||||
register: test4
|
||||
|
||||
|
|
@ -65,7 +67,9 @@
|
|||
state: present
|
||||
label:
|
||||
haha: kukuku
|
||||
llala: wiwiwiw
|
||||
LLALA: WIWIWIW
|
||||
OEIWIOP: eufslsa
|
||||
ieui4: KDJSL4D
|
||||
command: 1h
|
||||
register: test5
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue