From: Peter Souter Date: Thu, 4 Dec 2014 14:27:55 +0000 (+0000) Subject: (MODULES-444) - Check for accepting > 2 args X-Git-Url: https://gitweb.fluxo.info/?a=commitdiff_plain;h=368c97f08046696d453afca6e1f8001b5bfc88a5;p=puppet-stdlib.git (MODULES-444) - Check for accepting > 2 args --- diff --git a/spec/functions/concat_spec.rb b/spec/functions/concat_spec.rb index d443c4b..49fa6bb 100755 --- a/spec/functions/concat_spec.rb +++ b/spec/functions/concat_spec.rb @@ -13,6 +13,10 @@ describe "the concat function" do expect { scope.function_concat([1, []])}.to(raise_error(Puppet::ParseError)) end + it "should not raise a ParseError if the client provides more than two arguments" do + expect { scope.function_concat([[1],[2],[3]]) }.not_to raise_error + end + it "should be able to concat an array" do result = scope.function_concat([['1','2','3'],['4','5','6']]) expect(result).to(eq(['1','2','3','4','5','6']))