summaryrefslogtreecommitdiffstats
path: root/spec/integration
diff options
context:
space:
mode:
Diffstat (limited to 'spec/integration')
-rwxr-xr-xspec/integration/defaults_spec.rb15
1 files changed, 15 insertions, 0 deletions
diff --git a/spec/integration/defaults_spec.rb b/spec/integration/defaults_spec.rb
index 572d98cde..3178fca11 100755
--- a/spec/integration/defaults_spec.rb
+++ b/spec/integration/defaults_spec.rb
@@ -30,6 +30,21 @@ describe "Puppet defaults" do
end
end
+ describe "when setting the :node_name_fact" do
+ it "should fail when also setting :node_name_value" do
+ lambda do
+ Puppet.settings[:node_name_value] = "some value"
+ Puppet.settings[:node_name_fact] = "some_fact"
+ end.should raise_error("Cannot specify both the node_name_value and node_name_fact settings")
+ end
+
+ it "should not fail when using the default for :node_name_value" do
+ lambda do
+ Puppet.settings[:node_name_fact] = "some_fact"
+ end.should_not raise_error
+ end
+ end
+
describe "when configuring the :crl" do
it "should warn if :cacrl is set to false" do
Puppet.expects(:warning)