summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorTravis Fields <travis@puppetlabs.com>2014-10-29 20:03:07 -0700
committerTravis Fields <travis@puppetlabs.com>2014-10-29 20:03:07 -0700
commit6c7da72c0fa6b5e0ed3e5e2d5c80ff27f1e99dee (patch)
tree70285221d2e137c6aa73c5e70cac336ef5b77b57 /spec
parent385f0094883bf30c5ec7460bd0b7a1c4c29765a1 (diff)
downloadpuppet-stdlib-6c7da72c0fa6b5e0ed3e5e2d5c80ff27f1e99dee.tar.gz
puppet-stdlib-6c7da72c0fa6b5e0ed3e5e2d5c80ff27f1e99dee.tar.bz2
Fix validate_cmd, previous addition of SystemCallError only works for Puppet 3.7, previous version throw different exception. Wrapping in generic Exception catch all
Diffstat (limited to 'spec')
-rwxr-xr-xspec/acceptance/validate_cmd_spec.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/spec/acceptance/validate_cmd_spec.rb b/spec/acceptance/validate_cmd_spec.rb
index a899a1d..5ac66fd 100755
--- a/spec/acceptance/validate_cmd_spec.rb
+++ b/spec/acceptance/validate_cmd_spec.rb
@@ -40,7 +40,9 @@ describe 'validate_cmd function', :unless => UNSUPPORTED_PLATFORMS.include?(fact
validate_cmd($one,$two,"aoeu is dvorak")
EOS
- expect(apply_manifest(pp, :expect_failures => true).stderr).to match(/aoeu is dvorak/)
+ apply_manifest(pp, :expect_failures => true) do |output|
+ expect(output.stderr).to match(/aoeu is dvorak/)
+ end
end
end
describe 'failure' do