From dd160c202c6891e37c70ac35093ea3741c98c2ac Mon Sep 17 00:00:00 2001 From: Yannik Sembritzki Date: Tue, 2 Jul 2024 00:39:26 +0200 Subject: [PATCH] Improve task name --- plugins/module_utils/_ADObject.psm1 | 4 ++-- plugins/modules/group.py | 1 + tests/integration/targets/group/tasks/tests.yml | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/plugins/module_utils/_ADObject.psm1 b/plugins/module_utils/_ADObject.psm1 index 7c85a5d..206d1f3 100644 --- a/plugins/module_utils/_ADObject.psm1 +++ b/plugins/module_utils/_ADObject.psm1 @@ -543,7 +543,7 @@ Function ConvertTo-AnsibleADDistinguishedName { [string] $Server, - [boolean] + [Switch] $NestedGroupFlatten, [PSCredential] @@ -617,7 +617,7 @@ Function ConvertTo-AnsibleADDistinguishedName { $object = Get-AnsibleADObject @getParams if ($object) { if ($NestedGroupFlatten -and $object.ObjectClass -eq "group") { - $dns = Get-ADGroupMember $object -Recursive | Select-Object -ExpandProperty DistinguishedName + $dns = Get-ADGroupMember @getParams -Recursive $object | Select-Object -ExpandProperty DistinguishedName } else { $dns = $object | Select-Object -ExpandProperty DistinguishedName diff --git a/plugins/modules/group.py b/plugins/modules/group.py index ed8ef8a..0ef9ff6 100644 --- a/plugins/modules/group.py +++ b/plugins/modules/group.py @@ -91,6 +91,7 @@ - Flattens nested groups. type: bool default: false + version_added: 1.7.0 sam_account_name: description: - The C(sAMAccountName) value to set for the group. diff --git a/tests/integration/targets/group/tasks/tests.yml b/tests/integration/targets/group/tasks/tests.yml index 3b19938..b0ed48f 100644 --- a/tests/integration/targets/group/tasks/tests.yml +++ b/tests/integration/targets/group/tasks/tests.yml @@ -329,7 +329,7 @@ - my_user_2 register: sub_group - - name: set members while flattening sub group + - name: set members with sub group flattening group: name: MyGroup flatten: true