aboutsummaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorJosh Cooper <josh@puppet.com>2018-07-09 20:25:14 -0700
committerJosh Cooper <josh@puppet.com>2018-07-10 11:03:14 -0700
commit5f97412d3bbb80870d5194d5c5b04bc6643daa8b (patch)
treed323c656b6630496a4702548c94ebf40c80db2c4 /spec
parent460e81c81deb278eb9296a1336723ec8a5781b77 (diff)
downloadpuppet-hosts_core-5f97412d3bbb80870d5194d5c5b04bc6643daa8b.tar.gz
puppet-hosts_core-5f97412d3bbb80870d5194d5c5b04bc6643daa8b.tar.bz2
Remove Lint/HandleExceptions violations
Diffstat (limited to 'spec')
-rw-r--r--spec/lib/puppet_spec/files.rb8
1 files changed, 2 insertions, 6 deletions
diff --git a/spec/lib/puppet_spec/files.rb b/spec/lib/puppet_spec/files.rb
index 896fdac..08699f6 100644
--- a/spec/lib/puppet_spec/files.rb
+++ b/spec/lib/puppet_spec/files.rb
@@ -6,14 +6,10 @@ require 'pathname'
# A support module for testing files.
module PuppetSpec::Files
def self.cleanup
- begin
- Dir.unstub(:entries)
- FileUtils.rm_rf path, secure: true
- rescue Errno::ENOENT
- # nothing to do
- end
@global_tempfiles ||= []
while path = @global_tempfiles.pop
+ Dir.unstub(:entries)
+ FileUtils.rm_rf path, secure: true
end
end