summaryrefslogtreecommitdiffstats
path: root/spec/unit
diff options
context:
space:
mode:
authorLuke Kanies <luke@madstop.com>2008-06-11 18:52:05 -0500
committerLuke Kanies <luke@madstop.com>2008-06-11 18:52:05 -0500
commit4b29a5ea234e2c0c36ab5fca8fa0f6dee0085a7e (patch)
treeea71d478f74bcb7cae8b12cabb14d9630f83b288 /spec/unit
parent041ca27460013088b790fab377aba0a8e470ce51 (diff)
downloadpuppet-4b29a5ea234e2c0c36ab5fca8fa0f6dee0085a7e.tar.gz
puppet-4b29a5ea234e2c0c36ab5fca8fa0f6dee0085a7e.tar.xz
puppet-4b29a5ea234e2c0c36ab5fca8fa0f6dee0085a7e.zip
Fixing how the indirection tests for whether the request has node info.
My request authorization code changed the request to set its 'node' instance variable, rather than using its options, and I apparently didn't change the Indirection class to do this. I have *no* idea how these tests were passing before -- they passed for me yesterday but failed for Andrew, and today they started failing for me. Frightening.
Diffstat (limited to 'spec/unit')
-rwxr-xr-xspec/unit/indirector/indirection.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/spec/unit/indirector/indirection.rb b/spec/unit/indirector/indirection.rb
index cefd0557e..5d4539e95 100755
--- a/spec/unit/indirector/indirection.rb
+++ b/spec/unit/indirector/indirection.rb
@@ -6,7 +6,7 @@ require 'puppet/indirector/indirection'
describe "Indirection Delegator", :shared => true do
it "should create a request object with the appropriate method name and all of the passed arguments" do
- request = stub 'request', :options => {}
+ request = stub 'request', :node => nil
@indirection.expects(:request).with(@method, "mystuff", :one => :two).returns request
@@ -339,7 +339,7 @@ describe Puppet::Indirector::Indirection do
end
it "should use a request to save the object to the cache" do
- request = stub 'request', :instance => @instance, :options => {}
+ request = stub 'request', :instance => @instance, :node => nil
@indirection.expects(:request).returns request
@@ -370,8 +370,8 @@ describe Puppet::Indirector::Indirection do
end
it "should use a request instance to search in and remove objects from the cache" do
- destroy = stub 'destroy_request', :key => "/my/key", :options => {}
- find = stub 'destroy_request', :key => "/my/key", :options => {}
+ destroy = stub 'destroy_request', :key => "/my/key", :node => nil
+ find = stub 'destroy_request', :key => "/my/key", :node => nil
@indirection.expects(:request).with(:destroy, "/my/key").returns destroy
@indirection.expects(:request).with(:find, "/my/key").returns find