summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuke Kanies <luke@madstop.com>2009-05-09 13:27:46 -0700
committerLuke Kanies <luke@madstop.com>2009-05-27 10:57:45 -0500
commitab34cf610ee529fcbbf777aae7b382090af1a8b2 (patch)
tree17dc837ef4e7cce87dca4c039adf91a72ba6bb80
parent9d5d0a0d17d1043754c759b27b58697749b1b87e (diff)
downloadpuppet-ab34cf610ee529fcbbf777aae7b382090af1a8b2.tar.gz
puppet-ab34cf610ee529fcbbf777aae7b382090af1a8b2.tar.xz
puppet-ab34cf610ee529fcbbf777aae7b382090af1a8b2.zip
Fixing puppetmasterd tests when missing rack
Signed-off-by: Luke Kanies <luke@madstop.com>
-rw-r--r--spec/unit/application/puppetmasterd.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/spec/unit/application/puppetmasterd.rb b/spec/unit/application/puppetmasterd.rb
index df6f87895..59377abb0 100644
--- a/spec/unit/application/puppetmasterd.rb
+++ b/spec/unit/application/puppetmasterd.rb
@@ -264,7 +264,6 @@ describe "PuppetMaster" do
@server = stub_everything 'server'
Puppet::Network::Server.stubs(:new).returns(@server)
@app = stub_everything 'app'
- Puppet::Network::HTTP::Rack.stubs(:new).returns(@app)
Puppet::SSL::Host.stubs(:localhost)
Puppet::SSL::CertificateAuthority.stubs(:ca?)
Process.stubs(:uid).returns(1000)
@@ -338,6 +337,11 @@ describe "PuppetMaster" do
describe "with --rack" do
confine "Rack is not available" => Puppet.features.rack?
+ before do
+ require 'puppet/network/http/rack'
+ Puppet::Network::HTTP::Rack.stubs(:new).returns(@app)
+ end
+
it "it should create the app with REST and XMLRPC support" do
@puppetmasterd.options.stubs(:[]).with(:rack).returns(:true)