summaryrefslogtreecommitdiff
path: root/spec/unit/runner_spec.rb
diff options
context:
space:
mode:
authortyler-ball <tyleraball@gmail.com>2014-11-13 11:05:10 -0800
committertyler-ball <tyleraball@gmail.com>2014-11-13 11:05:10 -0800
commit13fba4b26511382037efb9e36ce84eda1ba569e1 (patch)
tree5e3e2dd4094480815d174b08aaea510b3f5cf269 /spec/unit/runner_spec.rb
parentf5b36609eeb85d060e61293678488490cd382ea1 (diff)
parent2f8a0e92db2244b9404472b8ecae52c373d758ea (diff)
downloadchef-tball/audit-tests.tar.gz
Merge branch 'audit-mode' into tball/audit-teststball/audit-tests
Diffstat (limited to 'spec/unit/runner_spec.rb')
-rw-r--r--spec/unit/runner_spec.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/spec/unit/runner_spec.rb b/spec/unit/runner_spec.rb
index 9bd4199418..b30f818da1 100644
--- a/spec/unit/runner_spec.rb
+++ b/spec/unit/runner_spec.rb
@@ -99,13 +99,15 @@ describe Chef::Runner do
end
context "when we fall through to old Chef::Platform resolution" do
+ let(:provider_resolver) { Chef::ProviderResolver.new(node, first_resource, nil) }
before do
# set up old Chef::Platform resolution instead of provider_resolver
Chef::Platform.set(
:resource => :cat,
:provider => Chef::Provider::SnakeOil
)
- allow(run_context.provider_resolver).to receive(:maybe_dynamic_provider_resolution).with(first_resource, anything()).and_return(nil)
+ allow(Chef::ProviderResolver).to receive(:new).and_return(provider_resolver)
+ allow(provider_resolver).to receive(:maybe_dynamic_provider_resolution).with(first_resource, anything()).and_return(nil)
end
it "should use the platform provider if it has one" do