diff options
author | Jesse Wolfe <jes5199@gmail.com> | 2009-12-14 23:47:48 -0800 |
---|---|---|
committer | James Turnbull <james@lovedthanlost.net> | 2009-12-16 18:01:45 +1100 |
commit | 3528a7b98c300f3ffa363d232b5f577f298390eb (patch) | |
tree | 3053d9b3e92a7e6304a04d715182a5ceea0c4d88 | |
parent | d343af0f2d115889543540bd3cc8bf66e9a9473e (diff) | |
download | puppet-3528a7b98c300f3ffa363d232b5f577f298390eb.tar.gz puppet-3528a7b98c300f3ffa363d232b5f577f298390eb.tar.xz puppet-3528a7b98c300f3ffa363d232b5f577f298390eb.zip |
2850 spec/unit/application/puppetd.rb generates warnings if run with certain other tests
Puppet[:libdir] is nil due to stubbing, causing an exception in autoload.
Depending on the order of loaded libs, sometimes this exception is
logged using Kernel#warn, but sometimes it's logged using Puppet.err
Only Kernel#warn writes to the terminal during unit testing!
-rwxr-xr-x | spec/unit/application/puppetd.rb | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/spec/unit/application/puppetd.rb b/spec/unit/application/puppetd.rb index e5a51675d..ec2fd546d 100755 --- a/spec/unit/application/puppetd.rb +++ b/spec/unit/application/puppetd.rb @@ -173,6 +173,7 @@ describe "puppetd" do Puppet.stubs(:info) FileTest.stubs(:exists?).returns(true) Puppet.stubs(:[]) + Puppet.stubs(:[]).with(:libdir).returns("/dev/null/lib") Puppet.settings.stubs(:print_config?) Puppet.settings.stubs(:print_config) Puppet::SSL::Host.stubs(:ca_location=) |