mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 21:32:49 +00:00
Add non_unique parameter for group module (#53085)
This commit is contained in:
committed by
Sam Doran
parent
0e77eeb205
commit
f97a593da5
@@ -23,6 +23,7 @@
|
||||
loop:
|
||||
- ansibullgroup
|
||||
- ansibullgroup2
|
||||
- ansibullgroup3
|
||||
|
||||
- block:
|
||||
- name: run tests
|
||||
@@ -36,3 +37,4 @@
|
||||
loop:
|
||||
- ansibullgroup
|
||||
- ansibullgroup2
|
||||
- ansibullgroup3
|
||||
@@ -129,6 +129,22 @@
|
||||
- not create_group_gid_again is changed
|
||||
- create_group_gid_again.gid | int == gid.stdout_lines[0] | int
|
||||
|
||||
- block:
|
||||
- name: create a group with a non-unique gid
|
||||
group:
|
||||
name: ansibullgroup3
|
||||
gid: '{{ gid.stdout_lines[0] }}'
|
||||
non_unique: true
|
||||
state: present
|
||||
register: create_group_gid_non_unique
|
||||
|
||||
- name: assert create group with a non unique gid
|
||||
assert:
|
||||
that:
|
||||
- create_group_gid_non_unique is changed
|
||||
- create_group_gid_non_unique.gid | int == gid.stdout_lines[0] | int
|
||||
when: ansible_facts.system != 'Darwin'
|
||||
|
||||
##
|
||||
## group remove
|
||||
##
|
||||
|
||||
Reference in New Issue
Block a user