summaryrefslogtreecommitdiff
path: root/spec/spec_helper.rb
diff options
context:
space:
mode:
authorJohn Keiser <jkeiser@opscode.com>2013-09-16 14:46:52 -0700
committerJohn Keiser <jkeiser@opscode.com>2013-09-16 14:46:52 -0700
commit03557d29a827a29065f323ca498869d0fefd3f02 (patch)
tree1e59aeaa04395d2e1cf47ac719ca9259ba8ceb47 /spec/spec_helper.rb
parent8fa661058877d5b465f4969e8fef9475af8f96a8 (diff)
downloadchef-03557d29a827a29065f323ca498869d0fefd3f02.tar.gz
Reset configuration before each test
Diffstat (limited to 'spec/spec_helper.rb')
-rw-r--r--spec/spec_helper.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index 41c9c821bd..f7b8302a52 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -67,6 +67,8 @@ require 'chef/applications'
require 'chef/shell'
require 'chef/util/file_edit'
+require 'chef/config'
+
# If you want to load anything into the testing environment
# without versioning it, add it to spec/support/local_gems.rb
require 'spec/support/local_gems.rb' if File.exists?(File.join(File.dirname(__FILE__), 'support', 'local_gems.rb'))
@@ -145,4 +147,8 @@ RSpec.configure do |config|
config.run_all_when_everything_filtered = true
config.treat_symbols_as_metadata_keys_with_true_values = true
+
+ config.before(:each) do
+ Chef::Config.reset
+ end
end