mirror of
https://github.com/inspec/inspec
synced 2024-09-21 15:02:01 +00:00
Merge pull request #4805 from inspec/maryj/CodeExUpdate
Update for Chef InSpec Resource Code Examples
This commit is contained in:
commit
1f77cb1369
2 changed files with 11 additions and 7 deletions
|
@ -43,11 +43,13 @@ The following examples show how to use this Chef InSpec audit resource.
|
|||
|
||||
describe ntp_conf do
|
||||
its('driftfile') { should eq '/var/lib/ntp/ntp.drift' }
|
||||
its('server') { should eq [
|
||||
0.ubuntu.pool.ntp.org,
|
||||
1.ubuntu.pool.ntp.org,
|
||||
2.ubuntu.pool.ntp.org
|
||||
] }
|
||||
its('server') do
|
||||
should eq [
|
||||
'0.ubuntu.pool.ntp.org',
|
||||
'1.ubuntu.pool.ntp.org',
|
||||
'2.ubuntu.pool.ntp.org'
|
||||
]
|
||||
end
|
||||
end
|
||||
|
||||
<br>
|
||||
|
|
|
@ -69,11 +69,13 @@ The following examples show how to use this Chef InSpec audit resource.
|
|||
its('Port') { should cmp 22 }
|
||||
its('UsePAM') { should eq 'yes' }
|
||||
its('ListenAddress') { should eq nil }
|
||||
its('HostKey') { should eq [
|
||||
its('HostKey') do
|
||||
should eq [
|
||||
'/etc/ssh/ssh_host_rsa_key',
|
||||
'/etc/ssh/ssh_host_dsa_key',
|
||||
'/etc/ssh/ssh_host_ecdsa_key',
|
||||
] }
|
||||
]
|
||||
end
|
||||
end
|
||||
|
||||
<br>
|
||||
|
|
Loading…
Reference in a new issue