summaryrefslogtreecommitdiffstats
path: root/spec/unit/application/agent_spec.rb
diff options
context:
space:
mode:
authorNick Lewis <nick@puppetlabs.com>2010-12-16 11:34:09 -0800
committerNick Lewis <nick@puppetlabs.com>2010-12-16 11:34:09 -0800
commita2ff092d8302e09aa79f9bb16636f8298316c3c7 (patch)
treecb67d36e37e252edceef1cd848cc32d679f5d20e /spec/unit/application/agent_spec.rb
parent4b35402ba85d8842d757becec5c8a7bf4d6f6654 (diff)
parent480c399f183627f5f588e9dc9f5f86f683c0e468 (diff)
downloadpuppet-a2ff092d8302e09aa79f9bb16636f8298316c3c7.tar.gz
puppet-a2ff092d8302e09aa79f9bb16636f8298316c3c7.tar.xz
puppet-a2ff092d8302e09aa79f9bb16636f8298316c3c7.zip
Merge branch 'next'
Diffstat (limited to 'spec/unit/application/agent_spec.rb')
-rwxr-xr-xspec/unit/application/agent_spec.rb24
1 files changed, 12 insertions, 12 deletions
diff --git a/spec/unit/application/agent_spec.rb b/spec/unit/application/agent_spec.rb
index 50ef00c57..cee6a0d1a 100755
--- a/spec/unit/application/agent_spec.rb
+++ b/spec/unit/application/agent_spec.rb
@@ -1,6 +1,6 @@
#!/usr/bin/env ruby
-require File.dirname(__FILE__) + '/../../spec_helper'
+require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper')
require 'puppet/agent'
require 'puppet/application/agent'
@@ -21,9 +21,9 @@ describe Puppet::Application::Agent do
Puppet::Util::Log.stubs(:newdestination)
Puppet::Util::Log.stubs(:level=)
- Puppet::Node.stubs(:terminus_class=)
- Puppet::Node.stubs(:cache_class=)
- Puppet::Node::Facts.stubs(:terminus_class=)
+ Puppet::Node.indirection.stubs(:terminus_class=)
+ Puppet::Node.indirection.stubs(:cache_class=)
+ Puppet::Node::Facts.indirection.stubs(:terminus_class=)
end
it "should operate in agent run_mode" do
@@ -179,11 +179,11 @@ describe Puppet::Application::Agent do
FileTest.stubs(:exists?).returns(true)
Puppet[:libdir] = "/dev/null/lib"
Puppet::SSL::Host.stubs(:ca_location=)
- Puppet::Transaction::Report.stubs(:terminus_class=)
- Puppet::Transaction::Report.stubs(:cache_class=)
- Puppet::Resource::Catalog.stubs(:terminus_class=)
- Puppet::Resource::Catalog.stubs(:cache_class=)
- Puppet::Node::Facts.stubs(:terminus_class=)
+ Puppet::Transaction::Report.indirection.stubs(:terminus_class=)
+ Puppet::Transaction::Report.indirection.stubs(:cache_class=)
+ Puppet::Resource::Catalog.indirection.stubs(:terminus_class=)
+ Puppet::Resource::Catalog.indirection.stubs(:cache_class=)
+ Puppet::Node::Facts.indirection.stubs(:terminus_class=)
@host = stub_everything 'host'
Puppet::SSL::Host.stubs(:new).returns(@host)
Puppet.stubs(:settraps)
@@ -307,13 +307,13 @@ describe Puppet::Application::Agent do
end
it "should tell the report handler to use REST" do
- Puppet::Transaction::Report.expects(:terminus_class=).with(:rest)
+ Puppet::Transaction::Report.indirection.expects(:terminus_class=).with(:rest)
@puppetd.setup
end
it "should tell the report handler to cache locally as yaml" do
- Puppet::Transaction::Report.expects(:cache_class=).with(:yaml)
+ Puppet::Transaction::Report.indirection.expects(:cache_class=).with(:yaml)
@puppetd.setup
end
@@ -325,7 +325,7 @@ describe Puppet::Application::Agent do
end
it "should tell the catalog handler to use cache" do
- Puppet::Resource::Catalog.expects(:cache_class=).with(:yaml)
+ Puppet::Resource::Catalog.indirection.expects(:cache_class=).with(:yaml)
@puppetd.setup
end