diff options
| author | Luke Kanies <luke@madstop.com> | 2009-05-27 10:11:25 -0500 |
|---|---|---|
| committer | Luke Kanies <luke@madstop.com> | 2009-05-27 10:19:50 -0500 |
| commit | b0ef08bfdfe3a1cdb81aa7622de0807786b24e3f (patch) | |
| tree | 6666a9d4c3cb28f3f6a352292de87757d4a071a3 /spec/unit/application | |
| parent | b83b159b69e1952c20f23629fc1255069ad5abb0 (diff) | |
| download | puppet-b0ef08bfdfe3a1cdb81aa7622de0807786b24e3f.tar.gz puppet-b0ef08bfdfe3a1cdb81aa7622de0807786b24e3f.tar.xz puppet-b0ef08bfdfe3a1cdb81aa7622de0807786b24e3f.zip | |
Fixing #2248 - --no-client correctly leaves off client
All of the settings were there, we just weren't doing anything
about them.
Signed-off-by: Luke Kanies <luke@madstop.com>
Diffstat (limited to 'spec/unit/application')
| -rwxr-xr-x | spec/unit/application/puppetd.rb | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/spec/unit/application/puppetd.rb b/spec/unit/application/puppetd.rb index dcd86185c..08f2a070a 100755 --- a/spec/unit/application/puppetd.rb +++ b/spec/unit/application/puppetd.rb @@ -327,11 +327,18 @@ describe "puppetd" do end end - it "should inform the daemon about our agent" do + it "should inform the daemon about our agent if :client is set to 'true'" do + @puppetd.options.expects(:[]).with(:client).returns true @daemon.expects(:agent=).with(@agent) @puppetd.run_setup end + it "should not inform the daemon about our agent if :client is set to 'false'" do + @puppetd.options[:client] = false + @daemon.expects(:agent=).never + @puppetd.run_setup + end + it "should daemonize if needed" do Puppet.stubs(:[]).with(:daemonize).returns(true) |
