diff options
author | Luke Kanies <luke@madstop.com> | 2008-05-13 16:00:58 -0500 |
---|---|---|
committer | Luke Kanies <luke@madstop.com> | 2008-05-13 16:00:58 -0500 |
commit | 6efe4000dda3379e867786a9c2d4ae0f0cdfc3be (patch) | |
tree | a16fd1ae1f4aab7fe04af88daa78f1be1a2b1f3e /spec/unit/network/http_pool.rb | |
parent | 68d8d0ae0686939d94dae8ccc70e5582187335dc (diff) | |
download | puppet-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/unit/network/http_pool.rb')
-rwxr-xr-x | spec/unit/network/http_pool.rb | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/spec/unit/network/http_pool.rb b/spec/unit/network/http_pool.rb index 04601769e..dd8bed54c 100755 --- a/spec/unit/network/http_pool.rb +++ b/spec/unit/network/http_pool.rb @@ -8,6 +8,7 @@ require 'puppet/network/http_pool' describe Puppet::Network::HttpPool do after do + Puppet::Util::Cacher.invalidate Puppet::Network::HttpPool.clear_http_instances Puppet::Network::HttpPool.instance_variable_set("@ssl_host", nil) end @@ -147,24 +148,6 @@ describe Puppet::Network::HttpPool do end end - # We mostly have to do this for testing, since in real life people - # won't change certs within a single process. - it "should remove its loaded certificate when clearing the cache" do - Puppet::Network::HttpPool.instance_variable_set("@cert", :yay) - Puppet::Network::HttpPool.clear_http_instances - # Can't use the accessor, because it will read the cert in - Puppet::Network::HttpPool.instance_variable_get("@cert").should be_nil - end - - # We mostly have to do this for testing, since in real life people - # won't change certs within a single process. - it "should remove its loaded key when clearing the cache" do - Puppet::Network::HttpPool.instance_variable_set("@key", :yay) - Puppet::Network::HttpPool.clear_http_instances - # Can't use the accessor, because it will read the cert in - Puppet::Network::HttpPool.instance_variable_get("@key").should be_nil - end - after do Puppet::Network::HttpPool.clear_http_instances end |