From 0b39d32f9b2fbfab83081db78600a27d3fa4a274 Mon Sep 17 00:00:00 2001 From: Jeff McCune Date: Thu, 29 Mar 2012 23:48:37 -0700 Subject: (#13439) Make spec_helper work with Puppet master Without this patch the spec_helper does not invoke Puppet.settings.send(:initialize_everything_for_tests) This is necessary to set default configuration settings, otherwise exceptions are raised when testing against the Puppet master branch. --- spec/spec_helper.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'spec') diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 10afd38..1474db1 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -11,9 +11,11 @@ RSpec.configure do |c| Dir.mkdir(manifestdir) FileUtils.touch(File.join(manifestdir, "site.pp")) Puppet[:confdir] = @puppetdir + Puppet.settings.send(:initialize_everything_for_tests) unless Puppet.version =~ /^2\.6/ end c.after :each do + Puppet.settings.send(:clear_everything_for_tests) unless Puppet.version =~ /^2\.6/ FileUtils.remove_entry_secure(@puppetdir) end -- cgit v1.2.3