From 5f600ddc04efd1c4faac9f63b3a07af5282be707 Mon Sep 17 00:00:00 2001 From: Luke Kanies Date: Sun, 15 Jun 2008 16:33:48 -0500 Subject: Fixing #1168 (for 0.24.x) -- automatically downcasing the fqdn. Also requiring that passed in certnames be downcased; the setting system isn't currently flexible enough to automatically downcase it for the user. --- spec/integration/defaults.rb | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'spec') diff --git a/spec/integration/defaults.rb b/spec/integration/defaults.rb index b14a141fb..a07743679 100755 --- a/spec/integration/defaults.rb +++ b/spec/integration/defaults.rb @@ -5,8 +5,9 @@ require File.dirname(__FILE__) + '/../spec_helper' require 'puppet/defaults' describe "Puppet defaults" do + after { Puppet.settings.clear } + describe "when setting the :factpath" do - after { Puppet.settings.clear } it "should add the :factpath to Facter's search paths" do Facter.expects(:search).with("/my/fact/path") @@ -14,4 +15,9 @@ describe "Puppet defaults" do Puppet.settings[:factpath] = "/my/fact/path" end end + describe "when setting the :certname" do + it "should fail if the certname is not downcased" do + lambda { Puppet.settings[:certname] = "Host.Domain.Com" }.should raise_error(ArgumentError) + end + end end -- cgit