mirror of
https://github.com/inspec/inspec
synced 2024-11-26 22:50:36 +00:00
Test fixture profile and input file for waivers
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
This commit is contained in:
parent
b82158ba53
commit
77b4e45175
3 changed files with 93 additions and 0 deletions
43
test/unit/mock/profiles/waivers/basic/controls/basic.rb
Normal file
43
test/unit/mock/profiles/waivers/basic/controls/basic.rb
Normal file
|
@ -0,0 +1,43 @@
|
|||
control "01_not_waivered_passes" do
|
||||
describe(true) { it { should eq true } }
|
||||
end
|
||||
|
||||
control "02_not_waivered_fails" do
|
||||
describe(true) { it { should eq false } }
|
||||
end
|
||||
|
||||
control "03_waivered_no_expiry_not_skipped_passes" do
|
||||
describe(true) { it { should eq true } }
|
||||
end
|
||||
|
||||
control "04_waivered_no_expiry_not_skipped_fails" do
|
||||
describe(true) { it { should eq false } }
|
||||
end
|
||||
|
||||
control "05_waivered_no_expiry_skipped" do
|
||||
describe(true) { it { should eq true } }
|
||||
end
|
||||
|
||||
control "06_waivered_expiry_in_past_not_skipped_passes" do
|
||||
describe(true) { it { should eq true } }
|
||||
end
|
||||
|
||||
control "07_waivered_expiry_in_past_not_skipped_fails" do
|
||||
describe(true) { it { should eq false } }
|
||||
end
|
||||
|
||||
control "08_waivered_expiry_in_past_skipped" do
|
||||
describe(true) { it { should eq true } }
|
||||
end
|
||||
|
||||
control "09_waivered_expiry_in_future_not_skipped_passes" do
|
||||
describe(true) { it { should eq true } }
|
||||
end
|
||||
|
||||
control "10_waivered_expiry_in_future_not_skipped_fails" do
|
||||
describe(true) { it { should eq false } }
|
||||
end
|
||||
|
||||
control "11_waivered_expiry_in_future_skipped" do
|
||||
describe(true) { it { should eq true } }
|
||||
end
|
44
test/unit/mock/profiles/waivers/basic/files/waivers.yaml
Normal file
44
test/unit/mock/profiles/waivers/basic/files/waivers.yaml
Normal file
|
@ -0,0 +1,44 @@
|
|||
waiver_03_waivered_no_expiry_not_skipped_passes:
|
||||
expiration_date: never
|
||||
justification: Sound reasoning
|
||||
skip: no
|
||||
|
||||
waiver_04_waivered_no_expiry_not_skipped_fails:
|
||||
expiration_date: never
|
||||
justification: Unassailable thinking
|
||||
skip: no
|
||||
|
||||
waiver_05_waivered_no_expiry_skipped:
|
||||
expiration_date: never
|
||||
justification: Sheer cleverness
|
||||
skip: yes
|
||||
|
||||
waiver_06_waivered_expiry_in_past_not_skipped_passes:
|
||||
expiration_date: 1977-06-01
|
||||
justification: Necessity
|
||||
skip: no
|
||||
|
||||
waiver_07_waivered_expiry_in_past_not_skipped_fails:
|
||||
expiration_date: 1977-06-01
|
||||
justification: Whimsy
|
||||
skip: no
|
||||
|
||||
waiver_08_waivered_expiry_in_past_skipped:
|
||||
expiration_date: 1977-06-01
|
||||
justification: Contrariness
|
||||
skip: yes
|
||||
|
||||
waiver_06_waivered_expiry_in_future_not_skipped_passes:
|
||||
expiration_date: 2077-06-01
|
||||
justification: Handwaving
|
||||
skip: no
|
||||
|
||||
waiver_07_waivered_expiry_in_future_not_skipped_fails:
|
||||
expiration_date: 2077-06-01
|
||||
justification: Didn't feel like it
|
||||
skip: no
|
||||
|
||||
waiver_08_waivered_expiry_in_future_skipped:
|
||||
expiration_date: 2077-06-01
|
||||
justification: Lack of imagination
|
||||
skip: yes
|
6
test/unit/mock/profiles/waivers/basic/inspec.yml
Normal file
6
test/unit/mock/profiles/waivers/basic/inspec.yml
Normal file
|
@ -0,0 +1,6 @@
|
|||
name: basic
|
||||
license: Apache-2.0
|
||||
summary: A profile that demonstrates basic usage of the waiver system
|
||||
version: 0.1.0
|
||||
supports:
|
||||
platform: os
|
Loading…
Reference in a new issue