summaryrefslogtreecommitdiffstats
path: root/spec/integration/node/facts.rb
diff options
context:
space:
mode:
authorLuke Kanies <luke@madstop.com>2008-05-13 16:00:58 -0500
committerLuke Kanies <luke@madstop.com>2008-05-13 16:00:58 -0500
commit6efe4000dda3379e867786a9c2d4ae0f0cdfc3be (patch)
treea16fd1ae1f4aab7fe04af88daa78f1be1a2b1f3e /spec/integration/node/facts.rb
parent68d8d0ae0686939d94dae8ccc70e5582187335dc (diff)
downloadpuppet-6efe4000dda3379e867786a9c2d4ae0f0cdfc3be.tar.gz
puppet-6efe4000dda3379e867786a9c2d4ae0f0cdfc3be.tar.xz
puppet-6efe4000dda3379e867786a9c2d4ae0f0cdfc3be.zip
Using the new Cacher class for handling cached data.
This provides a single, global bit for determining whether a given piece of cached data is still valid.
Diffstat (limited to 'spec/integration/node/facts.rb')
-rwxr-xr-xspec/integration/node/facts.rb6
1 files changed, 4 insertions, 2 deletions
diff --git a/spec/integration/node/facts.rb b/spec/integration/node/facts.rb
index c2f876578..cef3d79d4 100755
--- a/spec/integration/node/facts.rb
+++ b/spec/integration/node/facts.rb
@@ -7,13 +7,15 @@ require File.dirname(__FILE__) + '/../../spec_helper'
describe Puppet::Node::Facts do
describe "when using the indirector" do
- after { Puppet::Node::Facts.indirection.clear_cache }
+ after { Puppet::Util::Cacher.invalidate }
it "should expire any cached node instances when it is saved" do
Puppet::Node::Facts.indirection.stubs(:terminus_class).returns :yaml
+
+ Puppet::Node::Facts.indirection.terminus(:yaml).should equal(Puppet::Node::Facts.indirection.terminus(:yaml))
terminus = Puppet::Node::Facts.indirection.terminus(:yaml)
+ terminus.stubs :save
- terminus.expects(:save)
Puppet::Node.expects(:expire).with("me")
facts = Puppet::Node::Facts.new("me")