mirror of
https://github.com/inspec/inspec
synced 2024-11-23 13:13:22 +00:00
unique controls for dependency tests
This commit is contained in:
parent
bde8aa6768
commit
95029203cd
4 changed files with 17 additions and 7 deletions
|
@ -3,11 +3,12 @@
|
|||
include_controls 'profile_a'
|
||||
include_controls 'profile_b'
|
||||
include_controls 'os-hardening' do
|
||||
skip_control 'package-01'
|
||||
skip_control 'package-02'
|
||||
skip_control 'package-03'
|
||||
skip_control 'package-04'
|
||||
skip_control 'package-05'
|
||||
skip_control 'os-01'
|
||||
|
||||
1.upto(5) do |i|
|
||||
skip_control "package-%02d" % i
|
||||
end
|
||||
|
||||
1.upto(33) do |i|
|
||||
skip_control "sysctl-%02d" % i
|
||||
end
|
||||
|
|
|
@ -11,7 +11,7 @@ describe file('/tmp') do
|
|||
end
|
||||
|
||||
# you add controls here
|
||||
control 'tmp-1.0' do # A unique ID for this control
|
||||
control 'profilea-1' do # A unique ID for this control
|
||||
impact 0.7 # The criticality, if this control fails.
|
||||
title 'Create /tmp directory' # A human-readable title
|
||||
desc 'An optional description...'
|
||||
|
|
|
@ -10,7 +10,7 @@ describe file('/tmp') do
|
|||
end
|
||||
|
||||
# you add controls here
|
||||
control 'tmp-1.0' do # A unique ID for this control
|
||||
control 'profileb-1' do # A unique ID for this control
|
||||
impact 0.7 # The criticality, if this control fails.
|
||||
title 'Create /tmp directory' # A human-readable title
|
||||
desc 'An optional description...'
|
||||
|
|
|
@ -0,0 +1,9 @@
|
|||
# you add controls here
|
||||
control 'profilec-1' do # A unique ID for this control
|
||||
impact 0.7 # The criticality, if this control fails.
|
||||
title 'Create /tmp directory' # A human-readable title
|
||||
desc 'An optional description...'
|
||||
describe file('/tmp') do # The actual test
|
||||
it { should be_directory }
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue