From 57a5c0b3e36e1c01016865c264ca3642f64b5034 Mon Sep 17 00:00:00 2001 From: Matthew Haughton <3flex@users.noreply.github.com> Date: Tue, 29 Oct 2013 14:21:03 -0400 Subject: [PATCH] (Main) fix typo in pick error message Update pick error message "at least one non empty value" --- lib/puppet/parser/functions/pick.rb | 2 +- spec/unit/puppet/parser/functions/pick_spec.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) mode change 100644 => 100755 spec/unit/puppet/parser/functions/pick_spec.rb diff --git a/lib/puppet/parser/functions/pick.rb b/lib/puppet/parser/functions/pick.rb index e9e5d66..fdd0aef 100644 --- a/lib/puppet/parser/functions/pick.rb +++ b/lib/puppet/parser/functions/pick.rb @@ -21,7 +21,7 @@ EOS args.delete(:undefined) args.delete("") if args[0].to_s.empty? then - fail Puppet::ParseError, "pick(): must receive at last one non empty value" + fail Puppet::ParseError, "pick(): must receive at least one non empty value" else return args[0] end diff --git a/spec/unit/puppet/parser/functions/pick_spec.rb b/spec/unit/puppet/parser/functions/pick_spec.rb old mode 100644 new mode 100755 index d2b275f..f53fa80 --- a/spec/unit/puppet/parser/functions/pick_spec.rb +++ b/spec/unit/puppet/parser/functions/pick_spec.rb @@ -29,6 +29,6 @@ describe "the pick function" do end it 'should error if no values are passed' do - expect { scope.function_pick([]) }.to( raise_error(Puppet::ParseError, "pick(): must receive at last one non empty value")) + expect { scope.function_pick([]) }.to( raise_error(Puppet::ParseError, "pick(): must receive at least one non empty value")) end end