mirror of
https://github.com/inspec/inspec
synced 2024-11-26 22:50:36 +00:00
CFINSPEC-94: Refactor belongs_to_group
Signed-off-by: Sonu Saha <sonu.saha@progress.com>
This commit is contained in:
parent
2d068bee27
commit
91ffb07901
1 changed files with 1 additions and 9 deletions
|
@ -293,15 +293,7 @@ module Inspec::Resources
|
||||||
|
|
||||||
# belongs_to_group matcher: compatibility with serverspec
|
# belongs_to_group matcher: compatibility with serverspec
|
||||||
def belongs_to_group?(group_name)
|
def belongs_to_group?(group_name)
|
||||||
groupsname = groups
|
groups.include?(group_name)
|
||||||
is_valid_group = false
|
|
||||||
groupsname.each do |g|
|
|
||||||
if g == group_name
|
|
||||||
is_valid_group = true
|
|
||||||
break
|
|
||||||
end
|
|
||||||
end
|
|
||||||
is_valid_group
|
|
||||||
end
|
end
|
||||||
|
|
||||||
# encrypted_password property: compatibility with serverspec
|
# encrypted_password property: compatibility with serverspec
|
||||||
|
|
Loading…
Reference in a new issue