mirror of
https://github.com/inspec/inspec
synced 2024-11-10 23:24:18 +00:00
test case added for file resource when it does not exist
Signed-off-by: Nikita Mathur <nikita.mathur@chef.io>
This commit is contained in:
parent
483853ab81
commit
8403780995
1 changed files with 5 additions and 0 deletions
|
@ -104,4 +104,9 @@ describe Inspec::Resources::FileResource do
|
|||
|
||||
_(proc { resource.send(:more_permissive_than?, "0888") }).must_raise(ArgumentError)
|
||||
end
|
||||
|
||||
it "when file does not exist" do
|
||||
resource = MockLoader.new(:ubuntu1404).load_resource("file", "file_does_not_exist")
|
||||
assert_nil(resource.send(:more_permissive_than?, nil))
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue