diff options
Diffstat (limited to 'spec/integration/node.rb')
-rwxr-xr-x | spec/integration/node.rb | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/spec/integration/node.rb b/spec/integration/node.rb index b0375e743..de95d0e79 100755 --- a/spec/integration/node.rb +++ b/spec/integration/node.rb @@ -31,10 +31,11 @@ describe Puppet::Node do Puppet::Node.indirection.stubs(:terminus_class).returns :yaml # Load now, before we stub the exists? method. - Puppet::Node.indirection.terminus(:yaml) + terminus = Puppet::Node.indirection.terminus(:yaml) - file = File.join(Puppet[:yamldir], "node", "me.yaml") - FileTest.expects(:exist?).with(file).returns false + terminus.expects(:path).with(@name).returns "/my/yaml/file" + + FileTest.expects(:exist?).with("/my/yaml/file").returns false Puppet::Node.find(@name).should be_nil end |