summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuke Kanies <luke@madstop.com>2007-12-06 15:51:37 -0600
committerLuke Kanies <luke@madstop.com>2007-12-06 15:51:37 -0600
commit507406bd44f01e151483f148fadc8d50a9640984 (patch)
tree07898ee40e1ffb42757d0796c93951ced33d49a1
parent5886d37af0429728db42faf7e950d971145a643b (diff)
parenta012849e9ca496ccf72cbaf307f220f3891b802e (diff)
downloadpuppet-507406bd44f01e151483f148fadc8d50a9640984.tar.gz
puppet-507406bd44f01e151483f148fadc8d50a9640984.tar.xz
puppet-507406bd44f01e151483f148fadc8d50a9640984.zip
Merge commit 'mccune/pending/fix-896r3'
-rwxr-xr-xspec/unit/network/xmlrpc/client.rb10
-rwxr-xr-xtest/network/xmlrpc/client.rb5
2 files changed, 10 insertions, 5 deletions
diff --git a/spec/unit/network/xmlrpc/client.rb b/spec/unit/network/xmlrpc/client.rb
index b6ab4b367..78fe82719 100755
--- a/spec/unit/network/xmlrpc/client.rb
+++ b/spec/unit/network/xmlrpc/client.rb
@@ -25,6 +25,16 @@ describe Puppet::Network::XMLRPCClient, " when managing http instances" do
Puppet::Network::XMLRPCClient.http_instance("me", 54321).open_timeout.should == 120
end
+ it "should default to http_enable_post_connection_check being enabled" do
+ Puppet.settings[:http_enable_post_connection_check].should be_true
+ end
+
+ # JJM: I'm not sure if this is correct, as this really follows the
+ # configuration option.
+ it "should set enable_post_connection_check true " do
+ Puppet::Network::XMLRPCClient.http_instance("me", 54321).instance_variable_get("@enable_post_connection_check").should be_true
+ end
+
it "should create the http instance with the proxy host and port set if the http_proxy is not set to 'none'" do
Puppet.settings.stubs(:value).with(:http_keepalive).returns(true)
Puppet.settings.stubs(:value).with(:http_proxy_host).returns("myhost")
diff --git a/test/network/xmlrpc/client.rb b/test/network/xmlrpc/client.rb
index b150fdf99..f6d234324 100755
--- a/test/network/xmlrpc/client.rb
+++ b/test/network/xmlrpc/client.rb
@@ -72,11 +72,6 @@ class TestXMLRPCClient < Test::Unit::TestCase
http.expects(:cert=).with(:ccert)
http.expects(:key=).with(:ckey)
http.expects(:verify_mode=).with(OpenSSL::SSL::VERIFY_PEER)
- if Puppet[:http_enable_post_connection_check]
- http.expects(:enable_post_connection_check=).with(true)
- else
- http.expects(:enable_post_connection_check=).with(false)
- end
http.expects(:cert_store=)
assert_nothing_raised do