mirror of
https://github.com/inspec/inspec
synced 2025-02-17 06:28:40 +00:00
remove dup method users, use usernames, fix example
This commit is contained in:
parent
bc15c857b5
commit
4a676f55c3
1 changed files with 2 additions and 8 deletions
|
@ -16,8 +16,8 @@
|
||||||
# usage:
|
# usage:
|
||||||
#
|
#
|
||||||
# describe passwd do
|
# describe passwd do
|
||||||
# its(:usernames) { should eq 'root' }
|
# its(:usernames) { should eq ['root'] }
|
||||||
# its(:uids) { should eq 1 }
|
# its(:uids) { should eq [0] }
|
||||||
# end
|
# end
|
||||||
#
|
#
|
||||||
# describe passwd.uid(0) do
|
# describe passwd.uid(0) do
|
||||||
|
@ -63,12 +63,6 @@ class Passwd < Inspec.resource(1)
|
||||||
map_data('gid')
|
map_data('gid')
|
||||||
end
|
end
|
||||||
|
|
||||||
def users
|
|
||||||
@parsed.map {|x|
|
|
||||||
x['name']
|
|
||||||
}
|
|
||||||
end
|
|
||||||
|
|
||||||
def to_s
|
def to_s
|
||||||
'/etc/passwd'
|
'/etc/passwd'
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Reference in a new issue