diff options
author | Hunter Haugen <hunter@puppetlabs.com> | 2016-04-11 15:02:58 -0700 |
---|---|---|
committer | Hunter Haugen <hunter@puppetlabs.com> | 2016-04-11 15:02:58 -0700 |
commit | e3a6e2c601416ed7c656ccaf75eaec967f4eb687 (patch) | |
tree | 44f7aeb8e5288e65d6afe1185a0e9e55533c7e91 /spec/acceptance | |
parent | 60864fd39bcb22886749fc6d0a54eb09f8048516 (diff) | |
parent | 44596e73da1b157ea931d5111f842e108ca203bb (diff) |
Merge pull request #590 from alext/fix_concat_with_hash
(MODULES-3246) Fix concat with Hash arguments.
Diffstat (limited to 'spec/acceptance')
-rwxr-xr-x | spec/acceptance/concat_spec.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/spec/acceptance/concat_spec.rb b/spec/acceptance/concat_spec.rb index 06b649f..c472db6 100755 --- a/spec/acceptance/concat_spec.rb +++ b/spec/acceptance/concat_spec.rb @@ -36,5 +36,19 @@ describe 'concat function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('oper apply_manifest(pp, :catch_failures => true) end + it 'should concat hash arguments' do + pp = <<-EOS + $output = concat([{"a" => "b"}], {"c" => "d", "e" => "f"}) + validate_array($output) + if size($output) != 2 { + fail("${output} should have 2 elements.") + } + if $output[1] != {"c" => "d", "e" => "f"} { + fail("${output} does not have the expected hash for the second element.") + } + EOS + + apply_manifest(pp, :catch_failures => true) + end end end |