Changes in / [ad28f83:bcf0be5]
- Files:
-
- 36 added
- 148 deleted
- 343 edited
-
debian/changelog (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/hieradata/common.yaml (modified) (4 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/CHANGELOG.md (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/CONTRIBUTING.md (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/Gemfile (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/MAINTAINERS.md (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/NOTICE (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/README.md (modified) (9 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/Rakefile (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/checksums.json (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/examples/backports.pp (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/examples/key.pp (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/examples/source.pp (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/lib/facter/apt_updates.rb (modified) (5 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/lib/puppet/provider/apt_key/apt_key.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/lib/puppet/type/apt_key.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/locales/config.yaml (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/manifests/backports.pp (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/manifests/conf.pp (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/manifests/init.pp (modified) (5 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/manifests/key.pp (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/manifests/params.pp (modified) (6 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/manifests/pin.pp (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/manifests/ppa.pp (modified) (4 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/manifests/setting.pp (modified) (4 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/manifests/source.pp (modified) (6 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/manifests/update.pp (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/metadata.json (modified) (4 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/apt_key_provider_spec.rb (modified) (18 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/apt_spec.rb (modified) (4 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/class_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/centos-59-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/centos-64-x64-pe.yml (added)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/centos-65-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/centos-7-x64.yml (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/debian-70rc1-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/debian-73-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/debian-8-x64.yml (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/default.yml (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/docker/centos-7.yml (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/docker/debian-8.yml (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/docker/ubuntu-14.04.yml (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/ubuntu-server-10044-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/ubuntu-server-12042-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/ubuntu-server-1404-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/classes/apt_backports_spec.rb (modified) (12 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/classes/apt_spec.rb (modified) (10 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/classes/apt_update_spec.rb (modified) (7 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/classes/params_spec.rb (added)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/conf_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/key_compat_spec.rb (modified) (25 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/key_spec.rb (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/pin_spec.rb (modified) (4 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/ppa_spec.rb (modified) (21 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/setting_spec.rb (modified) (5 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/source_compat_spec.rb (modified) (8 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/source_spec.rb (modified) (17 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/spec.opts (added)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/spec_helper_acceptance.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/unit/facter/apt_has_updates_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/unit/facter/apt_package_updates_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/unit/facter/apt_security_updates_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/unit/facter/apt_update_last_success_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/unit/facter/apt_updates_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/apt/spec/unit/puppet/type/apt_key_spec.rb (modified) (19 diffs)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/15update-stamp.epp (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/15update-stamp.erb (added)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/_conf_header.epp (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/_conf_header.erb (added)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/_header.epp (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/_header.erb (added)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/conf.erb (added)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/pin.pref.epp (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/pin.pref.erb (added)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/proxy.epp (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/proxy.erb (added)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/source.list.epp (deleted)
-
src/puppetcode/environments/gnuboat/modules/apt/templates/source.list.erb (added)
-
src/puppetcode/environments/gnuboat/modules/chrony/LICENSE (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/README.md (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/Rakefile (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/checksums.json (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/manifests/config.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/manifests/init.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/manifests/install.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/manifests/params.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/manifests/service.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/metadata.json (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/spec/classes/init_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/spec/spec_helper.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/templates/chronyd.conf.erb (deleted)
-
src/puppetcode/environments/gnuboat/modules/chrony/tests/init.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/gnuboat_gpsd/manifests/service.pp (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/gnuboat_gpsd/templates/gpsd.epp (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/CHANGELOG.md (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/CONTRIBUTING.md (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/Gemfile (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/MAINTAINERS.md (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/README.markdown (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/README.md (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/Rakefile (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/appveyor.yml (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/checksums.json (modified) (5 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/examples/file_line.pp (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/facter/puppet_settings.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/facter/puppet_vardir.rb (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/deprecation.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/is_absolute_path.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/is_array.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/is_bool.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/is_float.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/is_ip_address.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/is_ipv4_address.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/is_ipv6_address.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/is_numeric.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/is_string.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/length.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/type_of.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_absolute_path.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_array.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_bool.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_hash.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_integer.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_ip_address.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_ipv4_address.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_ipv6_address.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_legacy.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_numeric.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_re.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_slength.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/validate_string.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/abs.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/any2bool.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/assert_private.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/base64.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/bool2num.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/bool2str.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/camelcase.rb (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/capitalize.rb (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/ceiling.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/chomp.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/chop.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/clamp.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/concat.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/count.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/defined_with_params.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/delete.rb (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/delete_at.rb (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/delete_regex.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/delete_undef_values.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/delete_values.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/deprecation.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/difference.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/dig.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/dig44.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/downcase.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/empty.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/enclose_ipv6.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/ensure_packages.rb (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/ensure_resources.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/flatten.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/floor.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/fqdn_rotate.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/fqdn_uuid.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/getparam.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/getvar.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/glob.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/grep.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/has_interface_with.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/has_ip_address.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/has_ip_network.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/hash.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/intersection.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_absolute_path.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_array.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_bool.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_domain_name.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_email_address.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_float.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_function_available.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_hash.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_integer.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_ip_address.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_ipv4_address.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_ipv6_address.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_mac_address.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_numeric.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_string.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/join.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/join_keys_to_values.rb (modified) (5 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/keys.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/loadjson.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/loadyaml.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/lstrip.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/max.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/member.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/min.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/num2bool.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/prefix.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/pry.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/pw_hash.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/range.rb (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/regexpescape.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/reverse.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/rstrip.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/shell_escape.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/shell_join.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/shell_split.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/shuffle.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/size.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/sort.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/squeeze.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/str2bool.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/str2saltedsha512.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/strftime.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/strip.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/suffix.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/swapcase.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/time.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/to_bytes.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/type3x.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/union.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/unique.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/upcase.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/uriescape.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_absolute_path.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_array.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_bool.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_email_address.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_hash.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_integer.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_ip_address.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_ipv4_address.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_ipv6_address.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_numeric.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_re.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_slength.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_string.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/values.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/values_at.rb (modified) (5 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/zip.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/provider/file_line/ruby.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/type/file_line.rb (modified) (5 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/locales/config.yaml (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/locales/ja/puppetlabs-stdlib.po (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/locales/puppetlabs-stdlib.pot (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/metadata.json (modified) (4 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/readmes/README_ja_JP.md (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/abs_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/anchor_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/any2array_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/base64_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/bool2num_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/capitalize_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/ceiling_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/chomp_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/chop_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/clamp_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/concat_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/count_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/deep_merge_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/defined_with_params_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/delete_at_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/delete_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/delete_undef_values_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/delete_values_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/deprecation_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/difference_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/dirname_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/downcase_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/empty_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/flatten_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/floor_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/fqdn_rand_string_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/fqdn_rotate_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/get_module_path_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/getparam_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/getvar_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/grep_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/has_interface_with_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/has_ip_address_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/has_ip_network_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/has_key_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/hash_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/intersection_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_a_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_array_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_bool_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_domain_name_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_float_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_function_available_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_hash_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_integer_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_ip_address_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_ipv4_address_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_ipv6_address_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_mac_address_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_numeric_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_string_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/join_keys_to_values_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/join_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/keys_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/loadjson_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/loadyaml_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/lstrip_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/max_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/member_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/merge_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/min_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/centos-59-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/centos-6-vcloud.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/centos-64-x64-pe.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/centos-64-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/centos-65-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/centos-7-x64.yml (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/debian-8-x64.yml (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/default.yml (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/docker/centos-7.yml (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/docker/debian-8.yml (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/docker/ubuntu-14.04.yml (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/fedora-18-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/sles-11-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/ubuntu-server-10044-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/ubuntu-server-12042-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/ubuntu-server-1404-x64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/windows-2003-i386.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/windows-2003-x86_64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/windows-2008-x86_64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/windows-2008r2-x86_64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/windows-2012-x86_64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/windows-2012r2-x86_64.yml (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/num2bool_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/parsejson_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/parseyaml_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/pick_default_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/pick_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/prefix_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/pw_hash_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/range_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/reject_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/reverse_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/rstrip_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/shuffle_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/size_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/sort_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/squeeze_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/str2bool_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/str2saltedsha512_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/strftime_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/strip_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/suffix_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/swapcase_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/time_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/to_bytes_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/try_get_value_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/type_spec.rb (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/union_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/unique_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/unsupported_spec.rb (added)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/upcase_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/uriescape_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_absolute_path_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_array_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_augeas_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_bool_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_cmd_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_hash_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_ipv4_address_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_ipv6_address_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_re_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_slength_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_string_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/values_at_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/values_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/zip_spec.rb (modified) (7 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/absolute_path_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/absolutepath_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/array_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/bool_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/float_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/hash_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/httpsurl_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/httpurl_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/integer_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/ip_address.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/ipv4_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/ipv6_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/numeric_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/string_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/unixpath_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/aliases/windowspath_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/dscacheutil/root (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/lsuser/root (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/absolute_path.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/absolutepath.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/array.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/bool.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/deftype.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/ensure_resources.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/float.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/hash.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/httpsurl.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/httpurl.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/integer.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/ip_address.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/ipv4.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/ipv6.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/numeric.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/string.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/unixpath.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/fixtures/test/manifests/windowspath.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/any2array_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/any2bool_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/assert_private_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/basename_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/chomp_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/chop_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/concat_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/count_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/deep_merge_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/defined_with_params_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/delete_at_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/delete_regex_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/delete_spec.rb (modified) (5 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/delete_undef_values_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/delete_values_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/deprecation_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/difference_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/dig44_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/dig_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/dirname_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/dos2unix_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/ensure_packages_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/ensure_resource_spec.rb (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/flatten_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/fqdn_rand_string_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/fqdn_rotate_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/fqdn_uuid_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/getparam_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/getvar_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/glob_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/grep_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/has_ip_network_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/has_key_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/hash_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/intersection_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_a_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_array_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_bool_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_float_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_integer_spec.rb (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_ip_address_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_ipv4_address_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_ipv6_address_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_mac_address_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_numeric_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_string_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/join_keys_to_values_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/join_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/keys_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/length.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/load_module_metadata_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/loadjson_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/loadyaml_spec.rb (modified) (3 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/lstrip_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/member_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/parsejson_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/parseyaml_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/pick_default_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/pick_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/prefix_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/range_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/regexpescape_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/reject_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/reverse_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/rstrip_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/seeded_rand_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/shell_escape_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/shell_join_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/shell_split_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/shuffle_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/size_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/squeeze_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/strip_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/suffix_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/union_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/unique_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_absolute_path_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_array_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_bool_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_cmd_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_hash_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_integer_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_ip_address_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_ipv4_address_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_ipv6_address_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_legacy_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_numeric_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_re_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_slength_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_string_spec.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/values_at_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/values_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/zip_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/spec_helper_acceptance.rb (modified) (2 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/spec_helper_local.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/support/shared_data.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/unit/ensure_resources_spec.rb (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/unit/puppet/provider/file_line/ruby_spec.rb (modified) (1 diff)
-
src/puppetcode/environments/gnuboat/modules/stdlib/spec/unit/puppet/type/file_line_spec.rb (modified) (5 diffs)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/absolutepath.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/compat/absolute_path.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/compat/array.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/compat/bool.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/compat/float.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/compat/hash.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/compat/integer.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/compat/ip_address.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/compat/ipv4.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/compat/ipv6.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/compat/numeric.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/compat/re.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/compat/string.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/httpsurl.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/httpurl.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/unixpath.pp (deleted)
-
src/puppetcode/environments/gnuboat/modules/stdlib/types/windowspath.pp (deleted)
Legend:
- Unmodified
- Added
- Removed
-
debian/changelog
rad28f83 rbcf0be5 1 gnuboat (0.4.5) jessie; urgency=low2 3 * Added chrony as time server sourcing gpsd4 5 -- EngSaS - Joachim Langenbach <info@engsas.de> Tue, 01 Aug 2017 15:45:00 +02006 1 gnuboat (0.4.4) jessie; urgency=low 7 2 -
src/puppetcode/environments/gnuboat/hieradata/common.yaml
rad28f83 rbcf0be5 8 8 - gnuboat_canboat 9 9 - apt 10 - chrony11 10 12 11 apt::sources: … … 23 22 # src: true 24 23 # deb: true 24 apt::sources: 25 25 'gnuboat-raspbian': 26 26 comment: 'GNUBoat raspbian repository' … … 50 50 gnuboat_gpsd::service::devices: '/dev/ttyACM0' 51 51 gnuboat_gpsd::service::network_access: true 52 gnuboat_gpsd::service::poll_on_startup: true53 52 gnuboat_gnuboat::service::status: 'running' 54 53 gnuboat_gnuboat::service::enabled: true … … 61 60 gnuboat_canboat::service::actisense_serial: 'Actisense_NGT-1_2C88A' 62 61 gnuboat_canboat::service::monitor: true 63 chrony::sync_local_clock: true64 chrony::offline: true65 chrony::refclock:66 - 'SHM 0 delay 0.5 refid NMEA'67 chrony::serve_ntp: true -
src/puppetcode/environments/gnuboat/modules/apt/CHANGELOG.md
rad28f83 rbcf0be5 1 ## Supported Release 4.1.02 ### Summary3 4 This release removes Data in Modules due to current compatibility issues and reinstates the params.pp file. Also includes a couple of bug fixes.5 6 #### Features7 - (MODULES-4973) Data in Modules which was introduced in the last release has now been reverted due to compatibility issues.8 9 #### Bugfixes10 - Now apt_key only sends the auth basic header when userinfo can be parsed from the URL.11 - Reverted the removal of Evolving Web's attribution in NOTICE file.12 - Test added to ensure empty string allowed for $release in apt::source.13 14 15 ## Supported Release 3.0.0 and 4.0.016 ###Summary17 18 This release adds new Puppet 4 features: data in modules, EPP templates, the $facts hash, and data types. This release is fully backwards compatible to existing Puppet 4 configurations and provides you with deprecation warnings for every argument that will not work as expected with the final 4.0.0 release. See the stdlib docs here for an in-depth discussion of this: https://github.com/puppetlabs/puppetlabs-stdlib#validate_legacy19 20 If you want to learn more about the new features used or you wish to upgrade a module yourself, have a look at the NTP: A Puppet 4 language update blog post.21 22 If you're still running Puppet 3, remain on the latest puppetlabs-apt 2.x release for now, and see the documentation to upgrade to Puppet 4.23 24 Changes25 26 Data in modules: Moves all distribution and OS-dependent defaults into YAML files in data/, alleviating the need for a params class. Note that while this feature is currently still classed as experimental, the final implementation will support the changes here.27 EPP templating: Uses the Puppet language as a base for templates to create simpler and safer templates. No need for Ruby anymore!28 The $facts hash: Makes facts visibly distinct from other variables for more readable and maintainable code. This helps eliminate confusion if you use a local variable whose name happens to match that of a common fact.29 Data types for validation: Helps you find and replace deprecated code in existing validate functions with stricter, more readable data type notation. First upgrade to the 3.0.0 release of this module, and address all deprecation warnings before upgrading to the final 4.0.0 release. Please see the stdlib docs for an in-depth discussion of this process.30 31 ## Supported Release 2.4.032 ### Summary33 A release that includes only a couple of additional features, but includes several cleanups and bugfixes around existing issues.34 35 #### Features36 - Tests updated to check for idempotency.37 - (MODULES-4224) Implementation of beaker-module_install_helper.38 - Deprecation warnings are now handled by the deprecation function in stdlib.39 40 #### Bugfixes41 - Now http and https sources fixed for apt_key and can take a userinfo.42 - GPG key update.43 - Notify_update param now defaults to true to avoid validation errors.44 - Implement retry on tests which pull key from a key server which sometimes times out (transient error).45 - String comparison error now comphensated for in update.pp.46 - (MODULES-4104) Removal of the port number from repository location in order to get the host name of the repository.47 - Puppet lint warnings addressed.48 - A few small readme issues addressed.49 50 ## Supported Release 2.3.051 ### Summary52 A release containing many bugfixes with additional features.53 54 #### Features55 - Apt_updates facts now use /usr/bin/apt-get.56 - Addition of notify update to apt::source.57 - Update to newest modulesync_configs.58 - Installs software-properties-common for Xenial.59 - Modulesync updates.60 - Add ability to specify a hash of apt::conf defines.61 62 #### Bugfixes63 - A clean up of spec/defines/key_compat_specs, also now runs under STRICT_VARIABLES.64 - Apt::setting expects priority to be an integer, set defaults accordingly.65 - Fixed version check for Ubuntu on 16.04.66 - Now uses hkps.pool.sks-keyservers.net instead of pgp.mit.edu.67 - Updates and fixes to tests. General cleanup.68 - Fixed regexp for $ensure params.69 - Apt/params: Remove unused LSB facts.70 - Replaced `-s` with `-f` in ppa rspec tests - After the repository is added, the "${::apt::sources_list_d}/${sources_list_d_filename}" file is created as an empty file. The unless condition of Exec["add-apt-repository-${name}"] calls test -s, which returns 1 if the file is empty. Because the file is empty, the unless condition is never true and the repository is added on every execution. This change replaces the -s test condition with -f, which is true if the file exists or false otherwise.71 - Limit non-strict parsing to pre-3.5.0 only - Puppet 3.5.0 introduced strict variables and the module handles strict variables by using the defined() function. This does not work on prior versions of puppet so we now gate based on that version. Puppet 4 series has a new setting `strict` that may be set to enforce strict variables while `strict_variables` remains unset (see PUP-6358) which causes the conditional in manifests/params.pp to erroniously use non-strict 3.5-era parsing and fail. This new conditional corrects the cases such that strict variable behavior happens on versions 3.5.0 and later.72 73 1 ##Supported Release 2.2.2 74 2 ###Summary 75 3 76 Several bug fixes and the addition of support updates to Debian 8 and Ubunt uWily.4 Several bug fixes and the addition of support updates to Debian 8 and Ubunto Wily. 77 5 78 6 ####Bugfixes 79 7 - Small fixes to descriptions within the readme and the addition of some examples. 80 - Updates to run on Ubunt uWily.8 - Updates to run on Ubunto Wily. 81 9 - Fixed apt_key tempfile race condition. 82 10 - Run stages limitation added to the documentation. -
src/puppetcode/environments/gnuboat/modules/apt/CONTRIBUTING.md
rad28f83 rbcf0be5 44 44 - Make sure you have a [GitHub account](https://github.com/join) 45 45 46 - [Create a ticket](https://tickets.puppet .com/secure/CreateIssue!default.jspa), or [watch the ticket](https://tickets.puppet.com/browse/) you are patching for.46 - [Create a ticket](https://tickets.puppetlabs.com/secure/CreateIssue!default.jspa), or [watch the ticket](https://tickets.puppetlabs.com/browse/) you are patching for. 47 47 48 48 * Preferred method: … … 209 209 ==================== 210 210 211 * [Getting additional help](http://puppet.com/community/get-help) 212 213 * [Writing tests](https://docs.puppet.com/guides/module_guides/bgtm.html#step-three-module-testing) 211 * [Getting additional help](http://puppetlabs.com/community/get-help) 212 213 * [Writing tests](http://projects.puppetlabs.com/projects/puppet/wiki/Development_Writing_Tests) 214 215 * [Patchwork](https://patchwork.puppetlabs.com) 214 216 215 217 * [General GitHub documentation](http://help.github.com/) 216 218 217 219 * [GitHub pull request documentation](http://help.github.com/send-pull-requests/) 220 -
src/puppetcode/environments/gnuboat/modules/apt/Gemfile
rad28f83 rbcf0be5 3 3 source ENV['GEM_SOURCE'] || "https://rubygems.org" 4 4 5 # Determines what type of gem is requested based on place_or_version. 6 def gem_type(place_or_version) 7 if place_or_version =~ /^git:/ 8 :git 9 elsif place_or_version =~ /^file:/ 10 :file 5 def location_for(place, version = nil) 6 if place =~ /^(git[:@][^#]*)#(.*)/ 7 [version, { :git => $1, :branch => $2, :require => false}].compact 8 elsif place =~ /^file:\/\/(.*)/ 9 ['>= 0', { :path => File.expand_path($1), :require => false}] 11 10 else 12 :gem11 [place, version, { :require => false}].compact 13 12 end 14 13 end 15 14 16 # Find a location or specific version for a gem. place_or_version can be a 17 # version, which is most often used. It can also be git, which is specified as 18 # `git://somewhere.git#branch`. You can also use a file source location, which 19 # is specified as `file://some/location/on/disk`. 20 def location_for(place_or_version, fake_version = nil) 21 if place_or_version =~ /^(git[:@][^#]*)#(.*)/ 22 [fake_version, { :git => $1, :branch => $2, :require => false }].compact 23 elsif place_or_version =~ /^file:\/\/(.*)/ 24 ['>= 0', { :path => File.expand_path($1), :require => false }] 25 else 26 [place_or_version, { :require => false }] 27 end 15 group :development, :unit_tests do 16 gem 'json', :require => false 17 gem 'metadata-json-lint', :require => false 18 gem 'puppet_facts', :require => false 19 gem 'puppet-blacksmith', :require => false 20 gem 'puppetlabs_spec_helper', :require => false 21 gem 'rspec-puppet', '>= 2.3.2', :require => false 22 gem 'simplecov', :require => false 23 end 24 group :system_tests do 25 gem 'beaker-rspec', *location_for(ENV['BEAKER_RSPEC_VERSION'] || '>= 3.4') 26 gem 'beaker', *location_for(ENV['BEAKER_VERSION']) 27 gem 'serverspec', :require => false 28 gem 'beaker-puppet_install_helper', :require => false 29 gem 'master_manipulator', :require => false 30 gem 'beaker-hostgenerator', *location_for(ENV['BEAKER_HOSTGENERATOR_VERSION']) 28 31 end 29 32 30 # Used for gem conditionals 31 supports_windows = false 32 ruby_version_segments = Gem::Version.new(RUBY_VERSION.dup).segments 33 minor_version = "#{ruby_version_segments[0]}.#{ruby_version_segments[1]}" 34 35 group :development do 36 gem "puppet-module-posix-default-r#{minor_version}", :require => false, :platforms => "ruby" 37 gem "puppet-module-win-default-r#{minor_version}", :require => false, :platforms => ["mswin", "mingw", "x64_mingw"] 38 gem "puppet-module-posix-dev-r#{minor_version}", :require => false, :platforms => "ruby" 39 gem "puppet-module-win-dev-r#{minor_version}", :require => false, :platforms => ["mswin", "mingw", "x64_mingw"] 40 gem "json_pure", '<= 2.0.1', :require => false if Gem::Version.new(RUBY_VERSION.dup) < Gem::Version.new('2.0.0') 41 gem "fast_gettext", '1.1.0', :require => false if Gem::Version.new(RUBY_VERSION.dup) < Gem::Version.new('2.1.0') 42 gem "fast_gettext", :require => false if Gem::Version.new(RUBY_VERSION.dup) >= Gem::Version.new('2.1.0') 43 end 44 45 group :system_tests do 46 gem "puppet-module-posix-system-r#{minor_version}", :require => false, :platforms => "ruby" 47 gem "puppet-module-win-system-r#{minor_version}", :require => false, :platforms => ["mswin", "mingw", "x64_mingw"] 48 gem "beaker", *location_for(ENV['BEAKER_VERSION'] || '>= 3') 49 gem "beaker-pe", :require => false 50 gem "beaker-rspec", *location_for(ENV['BEAKER_RSPEC_VERSION']) 51 gem "beaker-hostgenerator", *location_for(ENV['BEAKER_HOSTGENERATOR_VERSION']) 52 gem "beaker-abs", *location_for(ENV['BEAKER_ABS_VERSION'] || '~> 0.1') 53 end 54 33 gem 'facter', *location_for(ENV['FACTER_GEM_VERSION']) 55 34 gem 'puppet', *location_for(ENV['PUPPET_GEM_VERSION']) 56 35 57 # Only explicitly specify Facter/Hiera if a version has been specified.58 # Otherwise it can lead to strange bundler behavior. If you are seeing weird59 # gem resolution behavior, try setting `DEBUG_RESOLVER` environment variable60 # to `1` and then run bundle install.61 gem 'facter', *location_for(ENV['FACTER_GEM_VERSION']) if ENV['FACTER_GEM_VERSION']62 gem 'hiera', *location_for(ENV['HIERA_GEM_VERSION']) if ENV['HIERA_GEM_VERSION']63 36 64 65 # Evaluate Gemfile.local if it exists66 37 if File.exists? "#{__FILE__}.local" 67 38 eval(File.read("#{__FILE__}.local"), binding) 68 39 end 69 70 # Evaluate ~/.gemfile if it exists71 if File.exists?(File.join(Dir.home, '.gemfile'))72 eval(File.read(File.join(Dir.home, '.gemfile')), binding)73 end74 75 # vim:ft=ruby -
src/puppetcode/environments/gnuboat/modules/apt/NOTICE
rad28f83 rbcf0be5 1 Puppet Module - puppetlabs-apt 1 apt puppet module 2 2 3 Copyright 2017 Puppet, Inc. 3 Copyright (C) 2014-2016 Puppet Labs, Inc. 4 5 Puppet Labs can be contacted at: info@puppetlabs.com 6 4 7 5 8 Licensed under the Apache License, Version 2.0 (the "License"); … … 7 10 You may obtain a copy of the License at 8 11 9 http://www.apache.org/licenses/LICENSE-2.012 http://www.apache.org/licenses/LICENSE-2.0 10 13 11 14 Unless required by applicable law or agreed to in writing, software -
src/puppetcode/environments/gnuboat/modules/apt/README.md
rad28f83 rbcf0be5 59 59 **Warning:** Using short key IDs presents a serious security issue, potentially leaving you open to collision attacks. We recommend you always use full fingerprints to identify your GPG keys. This module allows short keys, but issues a security warning if you use them. 60 60 61 Declare the `apt::key` defined type:61 Declare the `apt::key` class: 62 62 63 63 ```puppet 64 64 apt::key { 'puppetlabs': 65 id => ' 6F6B15509CF8E59E6E469F327F438280EF8D349F',65 id => '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30', 66 66 server => 'pgp.mit.edu', 67 67 options => 'http-proxy="http://proxyuser:proxypass@example.org:3128"', … … 148 148 repos => 'main', 149 149 key => { 150 'id' => ' 6F6B15509CF8E59E6E469F327F438280EF8D349F',150 'id' => '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30', 151 151 'server' => 'pgp.mit.edu', 152 152 }, 153 } 153 }, 154 154 ``` 155 155 … … 179 179 repos: 'main' 180 180 key: 181 id: ' 6F6B15509CF8E59E6E469F327F438280EF8D349F'181 id: '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30' 182 182 server: 'pgp.mit.edu' 183 183 ``` … … 193 193 repos => 'main universe multiverse restricted', 194 194 } 195 195 196 196 apt::source { "archive.ubuntu.com-${lsbdistcodename}-security": 197 197 location => 'http://archive.ubuntu.com/ubuntu', … … 200 200 release => "${lsbdistcodename}-security" 201 201 } 202 202 203 203 apt::source { "archive.ubuntu.com-${lsbdistcodename}-updates": 204 204 location => 'http://archive.ubuntu.com/ubuntu', … … 207 207 release => "${lsbdistcodename}-updates" 208 208 } 209 209 210 210 apt::source { "archive.ubuntu.com-${lsbdistcodename}-backports": 211 211 location => 'http://archive.ubuntu.com/ubuntu', … … 261 261 ##### Parameters (all optional) 262 262 263 * `confs`: Creates new `apt::conf` resources. Valid options: a hash to be passed to the [`create_resources` function](https://docs.puppetlabs.com/references/latest/function.html#createresources). Default: {}.264 265 263 * `keys`: Creates new `apt::key` resources. Valid options: a hash to be passed to the [`create_resources` function](https://docs.puppetlabs.com/references/latest/function.html#createresources). Default: {}. 266 264 … … 423 421 424 422 * Lucid and Precise: 'python-software-properties' 425 * Trusty and newer: 'software-properties-common'426 * All others: 'python-software-properties'423 * Trusty, Utopic, and Vivid: 'software-properties-common' 424 * All others: undef 427 425 428 426 * `release`: *Optional if lsb-release is installed (unless you're using a different release than indicated by lsb-release, e.g., Linux Mint).* Specifies the operating system of your node. Valid options: a string containing a valid LSB distribution codename. Default: "$lsbdistcodename". 429 427 430 #### Defined Type: `apt: :setting`428 #### Defined Type: `apt:setting` 431 429 432 430 Manages Apt configuration files. … … 487 485 488 486 * `trusted_source`: Specifies whether to authenticate packages from this release, even if the Release file is not signed or the signature can't be checked. Valid options: 'true' and 'false'. Default: undef. This parameter is **deprecated** and will be removed in a future version of the module. 489 490 * `notify_update`: *Optional.* Specifies whether to trigger an `apt-get update` run. Valid options: 'true' and 'false'. Default: 'true'.491 487 492 488 #### Type: `apt_key` -
src/puppetcode/environments/gnuboat/modules/apt/Rakefile
rad28f83 rbcf0be5 1 require 'puppet_blacksmith/rake_tasks' 2 require 'puppet-lint/tasks/puppet-lint' 1 3 require 'puppetlabs_spec_helper/rake_tasks' 2 require 'puppet-lint/tasks/puppet-lint'3 require 'puppet_blacksmith/rake_tasks' if Bundler.rubygems.find_name('puppet-blacksmith').any?4 4 5 5 PuppetLint.configuration.fail_on_warnings = true 6 6 PuppetLint.configuration.send('relative') 7 PuppetLint.configuration.send('disable_80chars') 8 PuppetLint.configuration.send('disable_class_inherits_from_params_class') 9 PuppetLint.configuration.send('disable_documentation') 10 PuppetLint.configuration.send('disable_single_quote_string_with_variables') 11 PuppetLint.configuration.ignore_paths = ["spec/**/*.pp", "pkg/**/*.pp"] 7 12 8 13 desc 'Generate pooler nodesets' -
src/puppetcode/environments/gnuboat/modules/apt/checksums.json
rad28f83 rbcf0be5 1 1 { 2 "CHANGELOG.md": " a91cd94a75b1abd4b28b3ff089d81c60",3 "CONTRIBUTING.md": " 77d0440d7cd4206497f99065c60bed46",4 "Gemfile": " bedf635025b279d7c7732adcc8ae9a29",2 "CHANGELOG.md": "6a1e5e7a7b25137bab30512b425c0634", 3 "CONTRIBUTING.md": "ad65d271f183b5adb9fdd58207939f5f", 4 "Gemfile": "a5493d10f1c1fec87972b13a9fe1afcf", 5 5 "LICENSE": "3b83ef96387f14655fc854ddc3c6bd57", 6 "MAINTAINERS.md": "35674b233c6d12c0f56ee8afbdae29e4", 7 "NOTICE": "9533d13591355591f69619be28e9cfce", 8 "README.md": "06945ba980070be5f9e9b755fcfa4d8b", 9 "Rakefile": "3851f083966b9bbd6d46e50dba5aa52a", 10 "examples/backports.pp": "af57ea62ed1b73f540858e00327e6517", 6 "NOTICE": "f0fd8d07c4a816a2655400c7403db877", 7 "README.md": "f27f862d74944cbd90d6e9e310602eaa", 8 "Rakefile": "ab91824042ec3fd085a41cab7e0e90d4", 9 "examples/backports.pp": "17882e4b05751cd28069dcc72705e470", 11 10 "examples/builddep.pp": "eddb8b7d7c0ef7383d85a74c1cd0de3f", 12 11 "examples/debian_testing.pp": "2e50a41180e2afeac2de15ade05ddaa1", … … 16 15 "examples/force.pp": "f71857eba704a0eb3d8d6b146e80da6d", 17 16 "examples/hold.pp": "5e58e0a30d6407a05691d96c7647ae14", 18 "examples/key.pp": "d 85507365bd2753e14e04c344c2f7703",17 "examples/key.pp": "d1d63e76f1ca8a004dbeac9261c9045a", 19 18 "examples/pin.pp": "4b4c3612d75a19dba8eb7227070fa4ab", 20 19 "examples/ppa.pp": "b902cce8159128b5e8b21bed540743ff", 21 20 "examples/release.pp": "2bc960babf8c4dd24b7ffa4220a601f8", 22 "examples/source.pp": " c79817e129305f86a495f7558de3d3ec",21 "examples/source.pp": "2f402ae0218fdf070d5388a66e85f82f", 23 22 "examples/unattended_upgrades.pp": "e7a797388ef03077f110f4f268f5ecd1", 24 23 "lib/facter/apt_reboot_required.rb": "7c3fc46f254fc4b4579d011578caaadb", 25 24 "lib/facter/apt_update_last_success.rb": "2926ff059cd2f63a2a7824ba898837f9", 26 "lib/facter/apt_updates.rb": " 2662a82fe574e565d225f7838278d9eb",27 "lib/puppet/provider/apt_key/apt_key.rb": " 33d0ab1b0a21cea5c120d63173d514a4",28 "lib/puppet/type/apt_key.rb": " 9c6ca9618cdcb863275c23cf32c77f2d",25 "lib/facter/apt_updates.rb": "6c2f2204761b2d8842e0db6235d900cb", 26 "lib/puppet/provider/apt_key/apt_key.rb": "f6ad8e3cacfa8a199921730d61e96105", 27 "lib/puppet/type/apt_key.rb": "b167dc62db19a482a5b46abf3095904b", 29 28 "lib/puppet_x/apt_key/patch_openuri.rb": "951bad007a3b5db035be069c1d1c9c09", 30 "locales/config.yaml": "46660fe63119d48b8fb7dc3b38ee0856", 31 "manifests/backports.pp": "87a05ecfa0243d152ab225feec963d92", 32 "manifests/conf.pp": "8a33d3106e75422f82abc63ec41c4d84", 33 "manifests/init.pp": "fe403437b485318b9c9c384abfb6bb06", 34 "manifests/key.pp": "2ef8581029647d3d5a12234c86eff85f", 35 "manifests/params.pp": "621974da9b92d75e943aba2c1b384188", 36 "manifests/pin.pp": "d4fd040d22da4b418771a01fab8336fe", 37 "manifests/ppa.pp": "5c05b41477ba7613af1855ec38be5971", 38 "manifests/setting.pp": "50e39637905de1dfcfdaad95672a2890", 39 "manifests/source.pp": "797edd25ee64b3128a04dbf70e1443a4", 40 "manifests/update.pp": "46330dc5a8e69b62b2dfd9072cd4f26c", 41 "metadata.json": "fd6d46586030158faa92d2af7aa46e7b", 42 "spec/acceptance/apt_key_provider_spec.rb": "68e448171b89dcf535ac3f985937f1a7", 43 "spec/acceptance/apt_spec.rb": "7b2ed0430e2288250586c5a17a51c21c", 44 "spec/acceptance/class_spec.rb": "d3a2ff84333f0f9ee0143aeac414e46b", 45 "spec/acceptance/nodesets/centos-7-x64.yml": "a713f3abd3657f0ae2878829badd23cd", 46 "spec/acceptance/nodesets/debian-8-x64.yml": "d2d2977900989f30086ad251a14a1f39", 47 "spec/acceptance/nodesets/default.yml": "b42da5a1ea0c964567ba7495574b8808", 48 "spec/acceptance/nodesets/docker/centos-7.yml": "8a3892807bdd62306ae4774f41ba11ae", 49 "spec/acceptance/nodesets/docker/debian-8.yml": "ac8e871d1068c96de5e85a89daaec6df", 50 "spec/acceptance/nodesets/docker/ubuntu-14.04.yml": "dc42ee922a96908d85b8f0f08203ce58", 51 "spec/classes/apt_backports_spec.rb": "9a2c5fd8b451ace56fcbca4e89d9a397", 52 "spec/classes/apt_spec.rb": "1a132e04a5e9b4284105a6b2c8e202ce", 53 "spec/classes/apt_update_spec.rb": "2061f6c2827b0ab9a3b461b2bb40fbaf", 54 "spec/defines/conf_spec.rb": "57230dec18839ed45d695453f8e74978", 55 "spec/defines/key_compat_spec.rb": "970b0cec22e99af9cf158e4338fef5a1", 56 "spec/defines/key_spec.rb": "75f4d0880e7b3b4930f9fdf5cda760d1", 57 "spec/defines/pin_spec.rb": "3bab03c1ac67f651334fc1e7d0c97000", 58 "spec/defines/ppa_spec.rb": "7791f279e6c77f835fc4a21fbd6ec168", 59 "spec/defines/setting_spec.rb": "fb41b3d28b7e1860a53846d99b811677", 60 "spec/defines/source_compat_spec.rb": "8bed1d3acf3e6713d2795d4ab71ebb83", 61 "spec/defines/source_spec.rb": "32d68cce3d579e9121602d87b0078bab", 29 "manifests/backports.pp": "7d4a6e58ae3dc364e6279358e4f4b957", 30 "manifests/conf.pp": "403cee9be6284d6f47759482759f4b6d", 31 "manifests/init.pp": "3640560b938701bbc0c4ed8c93c5a64a", 32 "manifests/key.pp": "ad58e1224124b5b4a2617123d74eed00", 33 "manifests/params.pp": "d8799f415d36e4b50b1bf9a8a107a17c", 34 "manifests/pin.pp": "5abe01b9106f1f3c00f02e3ad81eec75", 35 "manifests/ppa.pp": "e745db50b160d7519e3dc97f137e0ca4", 36 "manifests/setting.pp": "cde5492c31b2b94c49bf67c7c96a6058", 37 "manifests/source.pp": "c1be91ad56665839711ada25c6f10850", 38 "manifests/update.pp": "93f132802d6280debfc46b35c656486f", 39 "metadata.json": "c6ad04eceebce0185b4882acb517a7da", 40 "spec/acceptance/apt_key_provider_spec.rb": "1e19756f710dbc8799b630721197786e", 41 "spec/acceptance/apt_spec.rb": "0bd13c6cb16e56d049ad0a5770f9c1f3", 42 "spec/acceptance/class_spec.rb": "7fa3ee3cade5e27891fe01aa8af8941d", 43 "spec/acceptance/nodesets/centos-59-x64.yml": "57eb3e471b9042a8ea40978c467f8151", 44 "spec/acceptance/nodesets/centos-64-x64-pe.yml": "ec075d95760df3d4702abea1ce0a829b", 45 "spec/acceptance/nodesets/centos-65-x64.yml": "3e5c36e6aa5a690229e720f4048bb8af", 46 "spec/acceptance/nodesets/debian-70rc1-x64.yml": "715f798e696d3582c66d13f0e8e5f009", 47 "spec/acceptance/nodesets/debian-73-x64.yml": "b44b7146a828c37482c06879862fb5d9", 48 "spec/acceptance/nodesets/default.yml": "e27bb4d7526ad3c7a1c4aeb87decec15", 49 "spec/acceptance/nodesets/ubuntu-server-10044-x64.yml": "75e86400b7889888dc0781c0ae1a1297", 50 "spec/acceptance/nodesets/ubuntu-server-12042-x64.yml": "d30d73e34cd50b043c7d14e305955269", 51 "spec/acceptance/nodesets/ubuntu-server-1404-x64.yml": "5f0aed10098ac5b78e4217bb27c7aaf0", 52 "spec/classes/apt_backports_spec.rb": "20492356c4ebddcfe8739b8f4a0beac6", 53 "spec/classes/apt_spec.rb": "73023d41e3d02b760bad354deae321a1", 54 "spec/classes/apt_update_spec.rb": "e1bae3848f53c709a14c1e6def93865e", 55 "spec/classes/params_spec.rb": "87ac980e35fbc87e4d5a61809b99c1d8", 56 "spec/defines/conf_spec.rb": "4c07a034a6e55098962535d5dca611b0", 57 "spec/defines/key_compat_spec.rb": "3676c87d803d19d92f35ba74bad1db7c", 58 "spec/defines/key_spec.rb": "a69d96e761e40767ee3526503b9ce63c", 59 "spec/defines/pin_spec.rb": "5a3866f7a49f88e6e14e3335872e387b", 60 "spec/defines/ppa_spec.rb": "b8aed505789e507775de01749cda49f4", 61 "spec/defines/setting_spec.rb": "740578ed09763c7573c0bfafab6c94a1", 62 "spec/defines/source_compat_spec.rb": "aee5bea3d7f13749f7e245efc572bb9e", 63 "spec/defines/source_spec.rb": "783ed8308e71699b7f0b6f7cc925d178", 64 "spec/spec.opts": "a600ded995d948e393fbe2320ba8e51c", 62 65 "spec/spec_helper.rb": "b2db3bc02b4ac2fd5142a6621c641b07", 63 "spec/spec_helper_acceptance.rb": " ba9896539a0b9d550e4d27803ba5214c",64 "spec/unit/facter/apt_has_updates_spec.rb": " 8294711c589fb1efa9aa23be0faf8500",65 "spec/unit/facter/apt_package_updates_spec.rb": " 2a0549f8656f094d9d0006ce12f61b2c",66 "spec/spec_helper_acceptance.rb": "2d4884491c0eed85a780cbe694074945", 67 "spec/unit/facter/apt_has_updates_spec.rb": "fdc0d48ed55ebc72ae16c3f09cf82d2c", 68 "spec/unit/facter/apt_package_updates_spec.rb": "9102ea3ea94a286f5accd2fb2f040725", 66 69 "spec/unit/facter/apt_reboot_required_spec.rb": "9d58cb2aeaed624f7c4ca118ec1b6410", 67 "spec/unit/facter/apt_security_updates_spec.rb": "ec8a6711feac739866743dfaf4baf3d0", 68 "spec/unit/facter/apt_update_last_success_spec.rb": "0c6320a500d44948b4ec965194970840", 69 "spec/unit/facter/apt_updates_spec.rb": "ffde1130fda5990d2786ff7878ade5e0", 70 "spec/unit/puppet/type/apt_key_spec.rb": "311c79d817ad03fbae8923fa2a075221", 71 "templates/15update-stamp.epp": "b9de0ac9e2c9854b1bb213e362dc4e41", 72 "templates/_conf_header.epp": "6f3077f2eabd3e929a44d55bc1c5446e", 73 "templates/_header.epp": "9300ac105fe777787ac9e793b8df8d25", 74 "templates/pin.pref.epp": "ab7a64e3779f93028fe965a6393fad74", 75 "templates/proxy.epp": "540643b8da51aa4cb209ab4713d3bbb3", 76 "templates/source.list.epp": "c32995778d056f204d51a6d79505a5aa" 70 "spec/unit/facter/apt_security_updates_spec.rb": "41c9c1d84a0feaa3938f6f3d8def9772", 71 "spec/unit/facter/apt_update_last_success_spec.rb": "cbc907ca27e6f9bb803fa9654c4a1836", 72 "spec/unit/facter/apt_updates_spec.rb": "22f290cfbe2dc1d6bb321ce782e90bb8", 73 "spec/unit/puppet/type/apt_key_spec.rb": "986c3cf60937eb89cbf6335dc7923dc5", 74 "templates/15update-stamp.erb": "b9de0ac9e2c9854b1bb213e362dc4e41", 75 "templates/_conf_header.erb": "6f3077f2eabd3e929a44d55bc1c5446e", 76 "templates/_header.erb": "9300ac105fe777787ac9e793b8df8d25", 77 "templates/conf.erb": "b4bc626b0d998cd681ee6b8c507c0d1d", 78 "templates/pin.pref.erb": "c3885c6816db46cf66e3a9bf57973c61", 79 "templates/proxy.erb": "3d0f7b88020d8a29bafc690e05ca69d6", 80 "templates/source.list.erb": "72648dd11918d5c03db82065d3bef73b" 77 81 } -
src/puppetcode/environments/gnuboat/modules/apt/examples/backports.pp
rad28f83 rbcf0be5 7 7 key => { 8 8 id => '630239CC130E1A7FD81A27B140976EAF437D05B5', 9 server => ' hkps.pool.sks-keyservers.net',9 server => 'pgp.mit.edu', 10 10 }, 11 11 } -
src/puppetcode/environments/gnuboat/modules/apt/examples/key.pp
rad28f83 rbcf0be5 1 1 # Declare Apt key for apt.puppetlabs.com source 2 2 apt::key { 'puppetlabs': 3 id => ' 6F6B15509CF8E59E6E469F327F438280EF8D349F',4 server => ' hkps.pool.sks-keyservers.net',3 id => '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30', 4 server => 'pgp.mit.edu', 5 5 options => 'http-proxy="http://proxyuser:proxypass@example.org:3128"', 6 6 } -
src/puppetcode/environments/gnuboat/modules/apt/examples/source.pp
rad28f83 rbcf0be5 8 8 repos => 'main', 9 9 key => { 10 id => ' 6F6B15509CF8E59E6E469F327F438280EF8D349F',11 server => ' hkps.pool.sks-keyservers.net',10 id => '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30', 11 server => 'pgp.mit.edu', 12 12 }, 13 13 } … … 20 20 key => { 21 21 id => 'A1BD8E9D78F7FE5C3E65D8AF8B48AD6246925553', 22 server => ' hkps.pool.sks-keyservers.net',22 server => 'subkeys.pgp.net', 23 23 }, 24 24 pin => '-10', … … 30 30 key => { 31 31 id => 'A1BD8E9D78F7FE5C3E65D8AF8B48AD6246925553', 32 server => ' hkps.pool.sks-keyservers.net',32 server => 'subkeys.pgp.net', 33 33 }, 34 34 pin => '-10', -
src/puppetcode/environments/gnuboat/modules/apt/lib/facter/apt_updates.rb
rad28f83 rbcf0be5 2 2 Facter.add("apt_has_updates") do 3 3 confine :osfamily => 'Debian' 4 if File.executable?("/usr/bin/apt-get") 5 apt_get_result = Facter::Util::Resolution.exec('/usr/bin/apt-get -s upgrade 2>&1') 6 if not apt_get_result.nil? 7 apt_package_updates = [[], []] 8 apt_get_result.each_line do |line| 9 if line =~ /^Inst\s/ 10 package = line.gsub(/^Inst\s([^\s]+)\s.*/, '\1').strip 11 apt_package_updates[0].push(package) 12 security_matches = [ 13 / Debian[^\s]+-updates /, 14 / Debian-Security:/, 15 / Ubuntu[^\s]+-security /, 16 / gNewSense[^\s]+-security / 17 ] 18 re = Regexp.union(security_matches) 19 if line.match(re) 20 apt_package_updates[1].push(package) 21 end 22 end 23 end 4 if File.executable?("/usr/lib/update-notifier/apt-check") 5 apt_check_result = Facter::Util::Resolution.exec('/usr/lib/update-notifier/apt-check 2>&1') 6 if not apt_check_result.nil? and apt_check_result =~ /^\d+;\d+$/ 7 apt_package_updates = apt_check_result.split(';') 24 8 end 25 9 end … … 27 11 setcode do 28 12 if not apt_package_updates.nil? and apt_package_updates.length == 2 29 apt_package_updates != [ [], []]13 apt_package_updates != ['0', '0'] 30 14 end 31 15 end … … 35 19 confine :apt_has_updates => true 36 20 setcode do 21 packages = Facter::Util::Resolution.exec('/usr/lib/update-notifier/apt-check -p 2>&1').split("\n") 37 22 if Facter.version < '2.0.0' 38 apt_package_updates[0].join(',')23 packages.join(',') 39 24 else 40 apt_package_updates[0]25 packages 41 26 end 42 27 end … … 46 31 confine :apt_has_updates => true 47 32 setcode do 48 Integer(apt_package_updates[0] .length)33 Integer(apt_package_updates[0]) 49 34 end 50 35 end … … 53 38 confine :apt_has_updates => true 54 39 setcode do 55 Integer(apt_package_updates[1] .length)40 Integer(apt_package_updates[1]) 56 41 end 57 42 end -
src/puppetcode/environments/gnuboat/modules/apt/lib/puppet/provider/apt_key/apt_key.rb
rad28f83 rbcf0be5 128 128 else 129 129 begin 130 # Only send basic auth if URL contains userinfo 131 # Some webservers (e.g. Amazon S3) return code 400 if empty basic auth is sent 132 if parsedValue.userinfo.nil? 133 key = parsedValue.read 134 else 135 user_pass = parsedValue.userinfo.split(':') 136 parsedValue.userinfo = '' 137 key = open(parsedValue, :http_basic_authentication => user_pass).read 138 end 130 key = parsedValue.read 139 131 rescue OpenURI::HTTPError, Net::FTPPermError => e 140 132 fail("#{e.message} for #{resource[:source]}") -
src/puppetcode/environments/gnuboat/modules/apt/lib/puppet/type/apt_key.rb
rad28f83 rbcf0be5 8 8 be manipulated through the `apt-key` command. 9 9 10 apt_key { ' 6F6B15509CF8E59E6E469F327F438280EF8D349F':10 apt_key { '4BD6EC30': 11 11 source => 'http://apt.puppetlabs.com/pubkey.gpg' 12 12 } -
src/puppetcode/environments/gnuboat/modules/apt/manifests/backports.pp
rad28f83 rbcf0be5 1 1 class apt::backports ( 2 Optional[String] $location= undef,3 Optional[String] $release= undef,4 Optional[String] $repos= undef,5 Optional[Variant[String, Hash]] $key= undef,6 Optional[Variant[Integer, String, Hash]] $pin= 200,2 $location = undef, 3 $release = undef, 4 $repos = undef, 5 $key = undef, 6 $pin = 200, 7 7 ){ 8 8 if $location { 9 validate_string($location) 9 10 $_location = $location 10 11 } 11 12 if $release { 13 validate_string($release) 12 14 $_release = $release 13 15 } 14 16 if $repos { 17 validate_string($repos) 15 18 $_repos = $repos 16 19 } 17 20 if $key { 21 unless is_hash($key) { 22 validate_string($key) 23 } 18 24 $_key = $key 19 25 } 20 if ($ facts['lsbdistid'] == 'Debian' or $facts['lsbdistid'] == 'Ubuntu') {26 if ($::apt::xfacts['lsbdistid'] == 'debian' or $::apt::xfacts['lsbdistid'] == 'ubuntu') { 21 27 unless $location { 22 28 $_location = $::apt::backports['location'] 23 29 } 24 30 unless $release { 25 $_release = "${ facts['lsbdistcodename']}-backports"31 $_release = "${::apt::xfacts['lsbdistcodename']}-backports" 26 32 } 27 33 unless $repos { -
src/puppetcode/environments/gnuboat/modules/apt/manifests/conf.pp
rad28f83 rbcf0be5 1 1 define apt::conf ( 2 Optional[String] $content= undef,3 Enum['present', 'absent'] $ensure= present,4 Variant[String, Integer] $priority = 50,5 Optional[Boolean] $notify_update= undef,2 $content = undef, 3 $ensure = present, 4 $priority = '50', 5 $notify_update = undef, 6 6 ) { 7 7 … … 12 12 } 13 13 14 $confheadertmp = epp('apt/_conf_header.epp')15 14 apt::setting { "conf-${name}": 16 15 ensure => $ensure, 17 16 priority => $priority, 18 content => "${confheadertmp}${content}",17 content => template('apt/_conf_header.erb', 'apt/conf.erb'), 19 18 notify_update => $notify_update, 20 19 } -
src/puppetcode/environments/gnuboat/modules/apt/manifests/init.pp
rad28f83 rbcf0be5 1 # == Class: apt2 1 # 3 # Manage APT (Advanced Packaging Tool) 4 # 5 class apt ( 6 Hash $update_defaults = $apt::params::update_defaults, 7 Hash $purge_defaults = $apt::params::purge_defaults, 8 Hash $proxy_defaults = $apt::params::proxy_defaults, 9 Hash $include_defaults = $apt::params::include_defaults, 10 String $provider = $apt::params::provider, 11 String $keyserver = $apt::params::keyserver, 12 Optional[String] $ppa_options = $apt::params::ppa_options, 13 Optional[String] $ppa_package = $apt::params::ppa_package, 14 Optional[Hash] $backports = $apt::params::backports, 15 Hash $confs = $apt::params::confs, 16 Hash $update = $apt::params::update, 17 Hash $purge = $apt::params::purge, 18 Hash $proxy = $apt::params::proxy, 19 Hash $sources = $apt::params::sources, 20 Hash $keys = $apt::params::keys, 21 Hash $ppas = $apt::params::ppas, 22 Hash $pins = $apt::params::pins, 23 Hash $settings = $apt::params::settings, 24 String $root = $apt::params::root, 25 String $sources_list = $apt::params::sources_list, 26 String $sources_list_d = $apt::params::sources_list_d, 27 String $conf_d = $apt::params::conf_d, 28 String $preferences = $apt::params::preferences, 29 String $preferences_d = $apt::params::preferences_d, 30 Hash $config_files = $apt::params::config_files, 31 Hash $source_key_defaults = $apt::params::source_key_defaults 32 ) inherits apt::params { 33 34 if $facts['osfamily'] != 'Debian' { 35 fail('This module only works on Debian or derivatives like Ubuntu') 36 } 2 class apt( 3 $update = {}, 4 $purge = {}, 5 $proxy = {}, 6 $sources = {}, 7 $keys = {}, 8 $ppas = {}, 9 $pins = {}, 10 $settings = {}, 11 ) inherits ::apt::params { 37 12 38 13 $frequency_options = ['always','daily','weekly','reluctantly'] 39 14 validate_hash($update) 40 15 if $update['frequency'] { 41 16 validate_re($update['frequency'], $frequency_options) 42 17 } 43 18 if $update['timeout'] { 44 assert_type(Integer, $update['timeout']) 19 unless is_integer($update['timeout']) { 20 fail('timeout value for update must be an integer') 21 } 45 22 } 46 23 if $update['tries'] { 47 assert_type(Integer, $update['tries']) 24 unless is_integer($update['tries']) { 25 fail('tries value for update must be an integer') 26 } 48 27 } 49 28 … … 51 30 include ::apt::update 52 31 32 validate_hash($purge) 53 33 if $purge['sources.list'] { 54 assert_type(Boolean,$purge['sources.list'])34 validate_bool($purge['sources.list']) 55 35 } 56 36 if $purge['sources.list.d'] { 57 assert_type(Boolean,$purge['sources.list.d'])37 validate_bool($purge['sources.list.d']) 58 38 } 59 39 if $purge['preferences'] { 60 assert_type(Boolean,$purge['preferences'])40 validate_bool($purge['preferences']) 61 41 } 62 42 if $purge['preferences.d'] { 63 assert_type(Boolean,$purge['preferences.d'])43 validate_bool($purge['preferences.d']) 64 44 } 65 45 66 46 $_purge = merge($::apt::purge_defaults, $purge) 67 47 48 validate_hash($proxy) 68 49 if $proxy['ensure'] { 69 50 validate_re($proxy['ensure'], ['file', 'present', 'absent']) 70 51 } 71 52 if $proxy['host'] { 72 assert_type(String,$proxy['host'])53 validate_string($proxy['host']) 73 54 } 74 55 if $proxy['port'] { 75 assert_type(Integer, $proxy['port']) 56 unless is_integer($proxy['port']) { 57 fail('$proxy port must be an integer') 58 } 76 59 } 77 if $proxy['https'] {78 assert_type(Boolean,$proxy['https'])60 if $proxy['https'] { 61 validate_bool($proxy['https']) 79 62 } 80 63 81 64 $_proxy = merge($apt::proxy_defaults, $proxy) 82 65 83 $confheadertmp = epp('apt/_conf_header.epp') 84 $proxytmp = epp('apt/proxy.epp', {'proxies' => $_proxy}) 85 $updatestamptmp = epp('apt/15update-stamp.epp') 66 validate_hash($sources) 67 validate_hash($keys) 68 validate_hash($settings) 69 validate_hash($ppas) 70 validate_hash($pins) 86 71 87 72 if $_proxy['ensure'] == 'absent' or $_proxy['host'] { … … 89 74 ensure => $_proxy['ensure'], 90 75 priority => '01', 91 content => "${confheadertmp}${proxytmp}",76 content => template('apt/_conf_header.erb', 'apt/proxy.erb'), 92 77 } 93 78 } … … 111 96 apt::setting { 'conf-update-stamp': 112 97 priority => 15, 113 content => "${confheadertmp}${updatestamptmp}",98 content => template('apt/_conf_header.erb', 'apt/15update-stamp.erb'), 114 99 } 115 100 … … 155 140 } 156 141 157 if $confs {158 create_resources('apt::conf', $confs)159 }160 142 # manage sources if present 161 143 if $sources { -
src/puppetcode/environments/gnuboat/modules/apt/manifests/key.pp
rad28f83 rbcf0be5 1 1 # == Define: apt::key 2 2 define apt::key ( 3 String $id = $title, 4 Enum['present', 'absent'] $ensure = present, 5 Optional[String] $content = undef, 6 Optional[String] $source = undef, 7 String $server = $::apt::keyserver, 8 Optional[String] $options = undef, 9 ) { 3 $id = $title, 4 $ensure = present, 5 $content = undef, 6 $source = undef, 7 $server = $::apt::keyserver, 8 $options = undef, 9 $key = undef, 10 $key_content = undef, 11 $key_source = undef, 12 $key_server = undef, 13 $key_options = undef, 14 ) { 10 15 11 validate_re($id, ['\A(0x)?[0-9a-fA-F]{8}\Z', '\A(0x)?[0-9a-fA-F]{16}\Z', '\A(0x)?[0-9a-fA-F]{40}\Z']) 12 13 if $source { 14 validate_re($source, ['\Ahttps?:\/\/', '\Aftp:\/\/', '\A\/\w+']) 16 if $key != undef { 17 warning('$key is deprecated and will be removed in the next major release. Please use $id instead.') 18 $_id = $key 19 } else { 20 $_id = $id 15 21 } 16 22 17 if $server { 18 validate_re($server,['\A((hkp|http|https):\/\/)?([a-z\d])([a-z\d-]{0,61}\.)+[a-z\d]+(:\d{2,5})?$']) 23 if $key_content != undef { 24 warning('$key_content is deprecated and will be removed in the next major release. Please use $content instead.') 25 $_content = $key_content 26 } else { 27 $_content = $content 28 } 29 30 if $key_source != undef { 31 warning('$key_source is deprecated and will be removed in the next major release. Please use $source instead.') 32 $_source = $key_source 33 } else { 34 $_source = $source 35 } 36 37 if $key_server != undef { 38 warning('$key_server is deprecated and will be removed in the next major release. Please use $server instead.') 39 $_server = $key_server 40 } else { 41 $_server = $server 42 } 43 44 if $key_options != undef { 45 warning('$key_options is deprecated and will be removed in the next major release. Please use $options instead.') 46 $_options = $key_options 47 } else { 48 $_options = $options 49 } 50 51 validate_re($_id, ['\A(0x)?[0-9a-fA-F]{8}\Z', '\A(0x)?[0-9a-fA-F]{16}\Z', '\A(0x)?[0-9a-fA-F]{40}\Z']) 52 validate_re($ensure, ['\Aabsent|present\Z',]) 53 54 if $_content { 55 validate_string($_content) 56 } 57 58 if $_source { 59 validate_re($_source, ['\Ahttps?:\/\/', '\Aftp:\/\/', '\A\/\w+']) 60 } 61 62 if $_server { 63 validate_re($_server,['\A((hkp|http|https):\/\/)?([a-z\d])([a-z\d-]{0,61}\.)+[a-z\d]+(:\d{2,5})?$']) 64 } 65 66 if $_options { 67 validate_string($_options) 19 68 } 20 69 21 70 case $ensure { 22 71 present: { 23 if defined(Anchor["apt_key ${ id} absent"]){24 fail("key with id ${ id} already ensured as absent")72 if defined(Anchor["apt_key ${_id} absent"]){ 73 fail("key with id ${_id} already ensured as absent") 25 74 } 26 75 27 if !defined(Anchor["apt_key ${ id} present"]) {76 if !defined(Anchor["apt_key ${_id} present"]) { 28 77 apt_key { $title: 29 78 ensure => $ensure, 30 id => $id, 31 source => $source, 32 content => $content, 33 server => $server, 34 options => $options, 35 } -> anchor { "apt_key ${id} present": } 79 id => $_id, 80 source => $_source, 81 content => $_content, 82 server => $_server, 83 options => $_options, 84 } -> 85 anchor { "apt_key ${_id} present": } 36 86 } 37 87 } 38 88 39 89 absent: { 40 if defined(Anchor["apt_key ${ id} present"]){41 fail("key with id ${ id} already ensured as present")90 if defined(Anchor["apt_key ${_id} present"]){ 91 fail("key with id ${_id} already ensured as present") 42 92 } 43 93 44 if !defined(Anchor["apt_key ${ id} absent"]){94 if !defined(Anchor["apt_key ${_id} absent"]){ 45 95 apt_key { $title: 46 96 ensure => $ensure, 47 id => $id, 48 source => $source, 49 content => $content, 50 server => $server, 51 options => $options, 52 } -> anchor { "apt_key ${id} absent": } 97 id => $_id, 98 source => $_source, 99 content => $_content, 100 server => $_server, 101 options => $_options, 102 } -> 103 anchor { "apt_key ${_id} absent": } 53 104 } 54 105 } -
src/puppetcode/environments/gnuboat/modules/apt/manifests/params.pp
rad28f83 rbcf0be5 3 3 if $::osfamily != 'Debian' { 4 4 fail('This module only works on Debian or derivatives like Ubuntu') 5 } 6 7 # prior to puppet 3.5.0, defined couldn't test if a variable was defined 8 # strict variables wasn't added until 3.5.0, so this should be fine. 9 if ! $::settings::strict_variables { 10 $xfacts = { 11 'lsbdistcodename' => $::lsbdistcodename, 12 'lsbdistrelease' => $::lsbdistrelease, 13 'lsbmajdistrelease' => $::lsbmajdistrelease, 14 'lsbdistdescription' => $::lsbdistdescription, 15 'lsbminordistrelease' => $::lsbminordistrelease, 16 'lsbdistid' => $::lsbdistid, 17 } 18 } else { 19 # Strict variables facts lookup compatibility 20 $xfacts = { 21 'lsbdistcodename' => defined('$lsbdistcodename') ? { 22 true => $::lsbdistcodename, 23 default => undef, 24 }, 25 'lsbdistrelease' => defined('$lsbdistrelease') ? { 26 true => $::lsbdistrelease, 27 default => undef, 28 }, 29 'lsbmajdistrelease' => defined('$lsbmajdistrelease') ? { 30 true => $::lsbmajdistrelease, 31 default => undef, 32 }, 33 'lsbdistdescription' => defined('$lsbdistdescription') ? { 34 true => $::lsbdistdescription, 35 default => undef, 36 }, 37 'lsbminordistrelease' => defined('$lsbminordistrelease') ? { 38 true => $::lsbminordistrelease, 39 default => undef, 40 }, 41 'lsbdistid' => defined('$lsbdistid') ? { 42 true => $::lsbdistid, 43 default => undef, 44 }, 45 } 5 46 } 6 47 … … 13 54 $preferences_d = "${root}/preferences.d" 14 55 $keyserver = 'keyserver.ubuntu.com' 15 $confs = {}16 $update = {}17 $purge = {}18 $proxy = {}19 $sources = {}20 $keys = {}21 $ppas = {}22 $pins = {}23 $settings = {}24 56 25 57 $config_files = { … … 70 102 } 71 103 72 case $ facts['os']['name']{73 ' Debian': {74 case $ facts['os']['release']['full'] {75 ' 6.0': {104 case $xfacts['lsbdistid'] { 105 'debian': { 106 case $xfacts['lsbdistcodename'] { 107 'squeeze': { 76 108 $backports = { 77 109 'location' => 'http://httpredir.debian.org/debian-backports', … … 93 125 94 126 } 95 ' Ubuntu': {127 'ubuntu': { 96 128 $backports = { 97 129 'location' => 'http://archive.ubuntu.com/ubuntu', … … 100 132 } 101 133 102 case $ facts['os']['release']['full'] {103 ' 10.04': {134 case $xfacts['lsbdistcodename'] { 135 'lucid': { 104 136 $ppa_options = undef 105 137 $ppa_package = 'python-software-properties' 106 138 } 107 ' 12.04': {139 'precise': { 108 140 $ppa_options = '-y' 109 141 $ppa_package = 'python-software-properties' 110 142 } 111 ' 14.04', '14.10', '15.04', '15.10': {143 'trusty', 'utopic', 'vivid', 'wily': { 112 144 $ppa_options = '-y' 113 145 $ppa_package = 'software-properties-common' … … 120 152 } 121 153 undef: { 122 fail('Unable to determine full release number')154 fail('Unable to determine lsbdistid, please install lsb-release first') 123 155 } 124 156 default: { -
src/puppetcode/environments/gnuboat/modules/apt/manifests/pin.pp
rad28f83 rbcf0be5 3 3 4 4 define apt::pin( 5 Optional[Enum['file', 'present', 'absent']] $ensure= present,6 Optional[String] $explanation= undef,7 Variant[Integer] $order = 50,8 Variant[String, Array] $packages= '*',9 Variant[Numeric, String] $priority= 0,10 Optional[String] $release= '', # a=11 Optional[String] $origin= '',12 Optional[String] $version= '',13 Optional[String] $codename= '', # n=14 Optional[String] $release_version= '', # v=15 Optional[String] $component= '', # c=16 Optional[String] $originator= '', # o=17 Optional[String] $label = '',# l=5 $ensure = present, 6 $explanation = undef, 7 $order = undef, 8 $packages = '*', 9 $priority = 0, 10 $release = '', # a= 11 $origin = '', 12 $version = '', 13 $codename = '', # n= 14 $release_version = '', # v= 15 $component = '', # c= 16 $originator = '', # o= 17 $label = '' # l= 18 18 ) { 19 if $order and !is_integer($order) { 20 fail('Only integers are allowed in the apt::pin order param') 21 } 19 22 20 23 if $explanation { … … 34 37 $component, 35 38 $originator, 36 $label, 37 ] 39 $label] 38 40 $pin_release = join($pin_release_array, '') 39 41 … … 70 72 $file_name = regsubst($title, '[^0-9a-z\-_\.]', '_', 'IG') 71 73 72 $headertmp = epp('apt/_header.epp')73 74 $pinpreftmp = epp('apt/pin.pref.epp', {75 'name' => $name,76 'pin_release' => $pin_release,77 'release' => $release,78 'codename' => $codename,79 'release_version' => $release_version,80 'component' => $component,81 'originator' => $originator,82 'label' => $label,83 'version' => $version,84 'origin' => $origin,85 'explanation' => $_explanation,86 'packages_string' => $packages_string,87 'priority' => $priority,88 })89 90 74 apt::setting { "pref-${file_name}": 91 75 ensure => $ensure, 92 76 priority => $order, 93 content => "${headertmp}${pinpreftmp}",77 content => template('apt/_header.erb', 'apt/pin.pref.erb'), 94 78 notify_update => false, 95 79 } -
src/puppetcode/environments/gnuboat/modules/apt/manifests/ppa.pp
rad28f83 rbcf0be5 1 1 # ppa.pp 2 2 define apt::ppa( 3 String $ensure= 'present',4 Optional[String] $options= $::apt::ppa_options,5 Optional[String] $release = $facts['lsbdistcodename'],6 Optional[String] $package_name= $::apt::ppa_package,7 Boolean $package_manage= false,3 $ensure = 'present', 4 $options = $::apt::ppa_options, 5 $release = $::apt::xfacts['lsbdistcodename'], 6 $package_name = $::apt::ppa_package, 7 $package_manage = false, 8 8 ) { 9 9 unless $release { … … 11 11 } 12 12 13 if $ facts['lsbdistid'] == 'Debian' {13 if $::apt::xfacts['lsbdistid'] == 'Debian' { 14 14 fail('apt::ppa is not currently supported on Debian.') 15 15 } 16 16 17 if versioncmp($facts['lsbdistrelease'], '15.10') >= 0 { 18 $distid = downcase($facts['lsbdistid']) 17 $ubuntu_release_year = regsubst($::apt::xfacts['lsbdistrelease'], '\.\d+$', '', 'G') + 0 18 $ubuntu_release_month = regsubst($::apt::xfacts['lsbdistrelease'], '^\d+\.', '', 'G') + 0 19 20 if $ubuntu_release_year >= 15 and $ubuntu_release_month >= 10 { 21 $distid = downcase($::apt::xfacts['lsbdistid']) 19 22 $filename = regsubst($name, '^ppa:([^/]+)/(.+)$', "\\1-${distid}-\\2-${release}") 20 23 } else { … … 29 32 if $package_manage { 30 33 ensure_packages($package_name) 34 31 35 $_require = [File['sources.list.d'], Package[$package_name]] 32 36 } else { … … 48 52 environment => $_proxy_env, 49 53 command => "/usr/bin/add-apt-repository ${options} ${name}", 50 unless => "/usr/bin/test - f${::apt::sources_list_d}/${sources_list_d_filename}",54 unless => "/usr/bin/test -s ${::apt::sources_list_d}/${sources_list_d_filename}", 51 55 user => 'root', 52 56 logoutput => 'on_failure', -
src/puppetcode/environments/gnuboat/modules/apt/manifests/setting.pp
rad28f83 rbcf0be5 1 1 define apt::setting ( 2 Variant[String, Integer, Array] $priority= 50,3 Optional[Enum['file', 'present', 'absent']] $ensure= file,4 Optional[String] $source= undef,5 Optional[String] $content= undef,6 Boolean $notify_update= true,2 $priority = 50, 3 $ensure = file, 4 $source = undef, 5 $content = undef, 6 $notify_update = true, 7 7 ) { 8 8 9 include 'apt::params' 9 10 if $content and $source { 10 11 fail('apt::setting cannot have both content and source') … … 14 15 fail('apt::setting needs either of content or source') 15 16 } 17 18 validate_re($ensure, ['file', 'present', 'absent']) 19 validate_bool($notify_update) 16 20 17 21 $title_array = split($title, '-') … … 26 30 } 27 31 32 if $source { 33 validate_string($source) 34 } 35 36 if $content { 37 validate_string($content) 38 } 39 28 40 if ($setting_type == 'list') or ($setting_type == 'pref') { 29 41 $_priority = '' … … 32 44 } 33 45 34 $_path = $::apt:: config_files[$setting_type]['path']35 $_ext = $::apt:: config_files[$setting_type]['ext']46 $_path = $::apt::params::config_files[$setting_type]['path'] 47 $_ext = $::apt::params::config_files[$setting_type]['ext'] 36 48 37 49 if $notify_update { -
src/puppetcode/environments/gnuboat/modules/apt/manifests/source.pp
rad28f83 rbcf0be5 2 2 # add an apt source 3 3 define apt::source( 4 Optional[String] $location = undef, 5 String $comment = $name, 6 String $ensure = present, 7 Optional[String] $release = undef, 8 String $repos = 'main', 9 Optional[Variant[Hash]] $include = {}, 10 Optional[Variant[String, Hash]] $key = undef, 11 $pin = undef, 12 Optional[String] $architecture = undef, 13 Boolean $allow_unsigned = false, 14 Boolean $notify_update = true, 4 $location = undef, 5 $comment = $name, 6 $ensure = present, 7 $release = undef, 8 $repos = 'main', 9 $include = {}, 10 $key = undef, 11 $pin = undef, 12 $architecture = undef, 13 $allow_unsigned = false, 14 $include_src = undef, 15 $include_deb = undef, 16 $required_packages = undef, 17 $key_server = undef, 18 $key_content = undef, 19 $key_source = undef, 20 $trusted_source = undef, 15 21 ) { 22 validate_string($architecture, $comment, $location, $repos) 23 validate_bool($allow_unsigned) 24 validate_hash($include) 16 25 17 26 # This is needed for compat with 1.8.x … … 20 29 $_before = Apt::Setting["list-${title}"] 21 30 22 if !$release { 23 if $facts['lsbdistcodename'] { 24 $_release = $facts['lsbdistcodename'] 25 } else { 31 if $include_src != undef { 32 warning("\$include_src is deprecated and will be removed in the next major release, please use \$include => { 'src' => ${include_src} } instead") 33 } 34 35 if $include_deb != undef { 36 warning("\$include_deb is deprecated and will be removed in the next major release, please use \$include => { 'deb' => ${include_deb} } instead") 37 } 38 39 if $required_packages != undef { 40 warning('$required_packages is deprecated and will be removed in the next major release, please use package resources instead.') 41 exec { "Required packages: '${required_packages}' for ${name}": 42 command => "${::apt::params::provider} -y install ${required_packages}", 43 logoutput => 'on_failure', 44 refreshonly => true, 45 tries => 3, 46 try_sleep => 1, 47 before => $_before, 48 } 49 } 50 51 if $key_server != undef { 52 warning("\$key_server is deprecated and will be removed in the next major release, please use \$key => { 'server' => ${key_server} } instead.") 53 } 54 55 if $key_content != undef { 56 warning("\$key_content is deprecated and will be removed in the next major release, please use \$key => { 'content' => ${key_content} } instead.") 57 } 58 59 if $key_source != undef { 60 warning("\$key_source is deprecated and will be removed in the next major release, please use \$key => { 'source' => ${key_source} } instead.") 61 } 62 63 if $trusted_source != undef { 64 warning('$trusted_source is deprecated and will be removed in the next major release, please use $allow_unsigned instead.') 65 $_allow_unsigned = $trusted_source 66 } else { 67 $_allow_unsigned = $allow_unsigned 68 } 69 70 if ! $release { 71 $_release = $::apt::params::xfacts['lsbdistcodename'] 72 unless $_release { 26 73 fail('lsbdistcodename fact not available: release parameter required') 27 74 } … … 34 81 } 35 82 36 $includes = merge($::apt::include_defaults, $include) 83 if $include_src != undef and $include_deb != undef { 84 $_deprecated_include = { 85 'src' => $include_src, 86 'deb' => $include_deb, 87 } 88 } elsif $include_src != undef { 89 $_deprecated_include = { 'src' => $include_src } 90 } elsif $include_deb != undef { 91 $_deprecated_include = { 'deb' => $include_deb } 92 } else { 93 $_deprecated_include = {} 94 } 95 96 $_include = merge($::apt::params::include_defaults, $_deprecated_include, $include) 97 98 $_deprecated_key = { 99 'key_server' => $key_server, 100 'key_content' => $key_content, 101 'key_source' => $key_source, 102 } 37 103 38 104 if $key { … … 41 107 fail('key hash must contain at least an id entry') 42 108 } 43 $_key = merge($::apt:: source_key_defaults, $key)109 $_key = merge($::apt::params::source_key_defaults, $_deprecated_key, $key) 44 110 } else { 45 validate_ legacy(String, 'validate_string',$key)46 $_key = { 'id' => $key }111 validate_string($key) 112 $_key = merge( { 'id' => $key }, $_deprecated_key) 47 113 } 48 114 } 49 115 50 $header = epp('apt/_header.epp')51 52 $sourcelist = epp('apt/source.list.epp', {53 'comment' => $comment,54 'includes' => $includes,55 'opt_architecture' => $architecture,56 'allow_unsigned' => $allow_unsigned,57 'location' => $location,58 'release' => $_release,59 'repos' => $repos,60 })61 62 116 apt::setting { "list-${name}": 63 ensure => $ensure, 64 content => "${header}${sourcelist}", 65 notify_update => $notify_update, 117 ensure => $ensure, 118 content => template('apt/_header.erb', 'apt/source.list.erb'), 66 119 } 67 120 … … 70 123 $_pin = merge($pin, { 'ensure' => $ensure, 'before' => $_before }) 71 124 } elsif (is_numeric($pin) or is_string($pin)) { 72 $url_split = split($location, ' [:\/]+')73 $host = $url_split[ 1]125 $url_split = split($location, '/') 126 $host = $url_split[2] 74 127 $_pin = { 75 128 'ensure' => $ensure, … … 88 141 if is_hash($_key) { 89 142 apt::key { "Add key: ${$_key['id']} from Apt::Source ${title}": 90 ensure => present, 91 id => $_key['id'], 92 server => $_key['server'], 93 content => $_key['content'], 94 source => $_key['source'], 95 options => $_key['options'], 96 before => $_before, 143 ensure => present, 144 id => $_key['id'], 145 server => $_key['server'], 146 content => $_key['content'], 147 source => $_key['source'], 148 options => $_key['options'], 149 key_server => $_key['key_server'], 150 key_content => $_key['key_content'], 151 key_source => $_key['key_source'], 152 before => $_before, 97 153 } 98 154 } -
src/puppetcode/environments/gnuboat/modules/apt/manifests/update.pp
rad28f83 rbcf0be5 14 14 $daily_threshold = (strftime('%s') - 86400) 15 15 if $::apt_update_last_success { 16 if $::apt_update_last_success + 0< $daily_threshold {16 if $::apt_update_last_success < $daily_threshold { 17 17 $_kick_apt = true 18 18 } else { … … 29 29 $weekly_threshold = (strftime('%s') - 604800) 30 30 if $::apt_update_last_success { 31 if ( $::apt_update_last_success + 0< $weekly_threshold ) {31 if ( $::apt_update_last_success < $weekly_threshold ) { 32 32 $_kick_apt = true 33 33 } else { -
src/puppetcode/environments/gnuboat/modules/apt/metadata.json
rad28f83 rbcf0be5 1 1 { 2 2 "name": "puppetlabs-apt", 3 "version": " 4.1.0",3 "version": "2.2.2", 4 4 "author": "Puppet Labs", 5 5 "summary": "Provides an interface for managing Apt source, key, and definitions with Puppet", … … 9 9 "issues_url": "https://tickets.puppetlabs.com/browse/MODULES", 10 10 "dependencies": [ 11 {"name":"puppetlabs/stdlib","version_requirement":">= 4. 16.0 < 5.0.0"}11 {"name":"puppetlabs/stdlib","version_requirement":">= 4.5.0 < 5.0.0"} 12 12 ], 13 "data_provider": null,14 13 "operatingsystem_support": [ 15 14 { … … 26 25 "10.04", 27 26 "12.04", 28 "14.04", 29 "16.04" 27 "14.04" 30 28 ] 31 29 } … … 33 31 "requirements": [ 34 32 { 33 "name": "pe", 34 "version_requirement": ">= 3.3.0 < 2015.4.0" 35 }, 36 { 35 37 "name": "puppet", 36 "version_requirement": ">= 4.7.0 < 5.0.0"38 "version_requirement": ">= 3.0.0 < 5.0.0" 37 39 } 38 40 ] -
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/apt_key_provider_spec.rb
rad28f83 rbcf0be5 1 1 require 'spec_helper_acceptance' 2 2 3 PUPPETLABS_GPG_KEY_SHORT_ID = ' EF8D349F'4 PUPPETLABS_GPG_KEY_LONG_ID = ' 7F438280EF8D349F'5 PUPPETLABS_GPG_KEY_FINGERPRINT = ' 6F6B15509CF8E59E6E469F327F438280EF8D349F'3 PUPPETLABS_GPG_KEY_SHORT_ID = '4BD6EC30' 4 PUPPETLABS_GPG_KEY_LONG_ID = '1054B7A24BD6EC30' 5 PUPPETLABS_GPG_KEY_FINGERPRINT = '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30' 6 6 PUPPETLABS_APT_URL = 'apt.puppetlabs.com' 7 PUPPETLABS_GPG_KEY_FILE = ' DEB-GPG-KEY-puppet'7 PUPPETLABS_GPG_KEY_FILE = 'pubkey.gpg' 8 8 CENTOS_GPG_KEY_SHORT_ID = 'C105B9DE' 9 9 CENTOS_GPG_KEY_LONG_ID = '0946FCA2C105B9DE' … … 12 12 CENTOS_GPG_KEY_FILE = 'RPM-GPG-KEY-CentOS-6' 13 13 14 SHOULD_NEVER_EXIST_ID = ' EF8D349F'14 SHOULD_NEVER_EXIST_ID = '4BD6EC30' 15 15 16 16 KEY_CHECK_COMMAND = "apt-key adv --list-keys --with-colons --fingerprint | grep " 17 17 PUPPETLABS_KEY_CHECK_COMMAND = "#{KEY_CHECK_COMMAND} #{PUPPETLABS_GPG_KEY_FINGERPRINT}" 18 18 CENTOS_KEY_CHECK_COMMAND = "#{KEY_CHECK_COMMAND} #{CENTOS_GPG_KEY_FINGERPRINT}" 19 20 MAX_TIMEOUT_RETRY = 321 TIMEOUT_RETRY_WAIT = 522 TIMEOUT_ERROR_MATCHER = /no valid OpenPGP data found/23 19 24 20 describe 'apt_key' do … … 34 30 describe 'default options' do 35 31 key_versions = { 36 '32bit key id' => "#{PUPPETLABS_GPG_KEY_SHORT_ID}",37 '64bit key id' => "#{PUPPETLABS_GPG_KEY_LONG_ID}",38 '160bit key fingerprint' => "#{PUPPETLABS_GPG_KEY_FINGERPRINT}",39 '32bit lowercase key id' => "#{PUPPETLABS_GPG_KEY_SHORT_ID.downcase}",40 '64bit lowercase key id' => "#{PUPPETLABS_GPG_KEY_LONG_ID.downcase}",41 '160bit lowercase key fingerprint' => "#{PUPPETLABS_GPG_KEY_FINGERPRINT.downcase}",42 '0x formatted 32bit key id' => "0x#{PUPPETLABS_GPG_KEY_SHORT_ID}",43 '0x formatted 64bit key id' => "0x#{PUPPETLABS_GPG_KEY_LONG_ID}",44 '0x formatted 160bit key fingerprint' => "0x#{PUPPETLABS_GPG_KEY_FINGERPRINT}",45 '0x formatted 32bit lowercase key id' => "0x#{PUPPETLABS_GPG_KEY_SHORT_ID.downcase}",46 '0x formatted 64bit lowercase key id' => "0x#{PUPPETLABS_GPG_KEY_LONG_ID.downcase}",47 '0x formatted 160bit lowercase key fingerprint' => "0x#{PUPPETLABS_GPG_KEY_FINGERPRINT.downcase}",32 '32bit key id' => '4BD6EC30', 33 '64bit key id' => '1054B7A24BD6EC30', 34 '160bit key fingerprint' => '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30', 35 '32bit lowercase key id' => '4bd6ec30', 36 '64bit lowercase key id' => '1054b7a24bd6ec30', 37 '160bit lowercase key fingerprint' => '47b320eb4c7c375aa9dae1a01054b7a24bd6ec30', 38 '0x formatted 32bit key id' => '0x4BD6EC30', 39 '0x formatted 64bit key id' => '0x1054B7A24BD6EC30', 40 '0x formatted 160bit key fingerprint' => '0x47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30', 41 '0x formatted 32bit lowercase key id' => '0x4bd6ec30', 42 '0x formatted 64bit lowercase key id' => '0x1054b7a24bd6ec30', 43 '0x formatted 160bit lowercase key fingerprint' => '0x47b320eb4c7c375aa9dae1a01054b7a24bd6ec30', 48 44 } 49 45 … … 69 65 pp = <<-EOS 70 66 apt_key { 'puppetlabs': 71 id => ' 8280EF8D349F',67 id => '4B7A24BD6EC30', 72 68 } 73 69 EOS … … 90 86 EOS 91 87 92 # Install the key first (retry because key pool may timeout) 93 retry_on_error_matching(MAX_TIMEOUT_RETRY, TIMEOUT_RETRY_WAIT, TIMEOUT_ERROR_MATCHER) do 94 shell("apt-key adv --keyserver hkps.pool.sks-keyservers.net \ 88 # Install the key first 89 shell("apt-key adv --keyserver keyserver.ubuntu.com \ 95 90 --recv-keys #{CENTOS_GPG_KEY_FINGERPRINT}") 96 end97 91 shell(CENTOS_KEY_CHECK_COMMAND) 98 92 99 93 # Time to remove it using Puppet 100 94 apply_manifest(pp, :catch_failures => true) 101 apply_manifest(pp, :catch_ changes => true)95 apply_manifest(pp, :catch_failures => true) 102 96 103 97 shell(CENTOS_KEY_CHECK_COMMAND, 104 98 :acceptable_exit_codes => [1]) 105 99 106 # Re-Install the key (retry because key pool may timeout) 107 retry_on_error_matching(MAX_TIMEOUT_RETRY, TIMEOUT_RETRY_WAIT, TIMEOUT_ERROR_MATCHER) do 108 shell("apt-key adv --keyserver hkps.pool.sks-keyservers.net \ 109 --recv-keys #{CENTOS_GPG_KEY_FINGERPRINT}") 110 end 100 shell("apt-key adv --keyserver keyserver.ubuntu.com \ 101 --recv-keys #{CENTOS_GPG_KEY_FINGERPRINT}") 111 102 end 112 103 end … … 121 112 EOS 122 113 123 # Install the key first (retry because key pool may timeout) 124 retry_on_error_matching(MAX_TIMEOUT_RETRY, TIMEOUT_RETRY_WAIT, TIMEOUT_ERROR_MATCHER) do 125 shell("apt-key adv --keyserver hkps.pool.sks-keyservers.net \ 126 --recv-keys #{PUPPETLABS_GPG_KEY_LONG_ID}") 127 end 128 114 # Install the key first 115 shell("apt-key adv --keyserver keyserver.ubuntu.com \ 116 --recv-keys #{PUPPETLABS_GPG_KEY_LONG_ID}") 129 117 shell(PUPPETLABS_KEY_CHECK_COMMAND) 130 118 131 119 # Time to remove it using Puppet 132 120 apply_manifest(pp, :catch_failures => true) 133 apply_manifest(pp, :catch_ changes => true)121 apply_manifest(pp, :catch_failures => true) 134 122 135 123 shell(PUPPETLABS_KEY_CHECK_COMMAND, … … 147 135 ensure => 'present', 148 136 content => "-----BEGIN PGP PUBLIC KEY BLOCK----- 149 150 mQINBFe2Iz4BEADqbv/nWmR26bsivTDOLqrfBEvRu9kSfDMzYh9Bmik1A8Z036Eg 151 h5+TZD8Rrd5TErLQ6eZFmQXk9yKFoa9/C4aBjmsL/u0yeMmVb7/66i+x3eAYGLzV 152 FyunArjtefZyxq0B2mdRHE8kwl5XGl8015T5RGHCTEhpX14O9yigI7gtliRoZcl3 153 hfXtedcvweOf9VrV+t5LF4PrZejom8VcB5CE2pdQ+23KZD48+Cx/sHSLHDtahOTQ 154 5HgwOLK7rBll8djFgIqP/UvhOqnZGIsg4MzTvWd/vwanocfY8BPwwodpX6rPUrD2 155 aXPsaPeM3Q0juDnJT03c4i0jwCoYPg865sqBBrpOQyefxWD6UzGKYkZbaKeobrTB 156 xUKUlaz5agSK12j4N+cqVuZUBAWcokXLRrcftt55B8jz/Mwhx8kl6Qtrnzco9tBG 157 T5JN5vXMkETDjN/T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sQyFhV3P+6SWnaC2TldWpfG/2pCSaSa8dbYbRe3SUNKXwT8kw3WoQYNofF6n 190 or8oFVA+UIVlvHc5h7L3tfFylRy5CwtR5rBQtoBicRVxEQc7ARNmB1XWuPntMQl/ 191 N1Fcfc+KSILFblAR6eVv+6BhMvRqzxqe81AEAP+oKVVwJ7H+wTQun2UKAgZATDWP 192 /LQsYinmLADpraDPqxT2WJe8kjszMDQZCK+jhsVrhZdkiw9EHAM0z7BKz6JERmLu 193 TIEcickkTfzbJWXZgv40Bvl99yPMswnR1lQHD7TKxyHYrI7dzJQri4mbORg4lOnZ 194 3Tyodv21Ocf4as2No1p6esZW+M46zjZeO8zzExmmENI2+P7/VUt+LWyQFiqRM0iW 195 zGioYMWgVePywFGaTV51/0uF9ymHHC7BDIcLgUWHdg/1B67jR5YQfzPJUqLhnylt 196 1sjDRQIlf+3U+ddvre2YxX/rYUI2gBT32QzQrv016KsiZO+N+Iya3B4D68s6xxQS 197 3xJn 198 =mMjt 199 -----END PGP PUBLIC KEY BLOCK-----", 200 } 201 EOS 202 203 #Apply the manifest (Retry if timeout error is received from key pool) 204 retry_on_error_matching(MAX_TIMEOUT_RETRY, TIMEOUT_RETRY_WAIT, TIMEOUT_ERROR_MATCHER) do 205 apply_manifest(pp, :catch_failures => true) 206 end 207 208 apply_manifest(pp, :catch_changes => true) 209 shell(PUPPETLABS_KEY_CHECK_COMMAND) 210 end 211 end 212 213 214 context 'multiple keys' do 215 it 'runs without errors' do 216 pp = <<-EOS 217 apt_key { 'puppetlabs': 218 id => '#{PUPPETLABS_GPG_KEY_FINGERPRINT}', 219 ensure => 'present', 220 content => "-----BEGIN PGP PUBLIC KEY BLOCK----- 221 Version: GnuPG v1 137 Version: GnuPG v1.4.12 (GNU/Linux) 138 Comment: GPGTools - http://gpgtools.org 222 139 223 140 mQINBEw3u0ABEAC1+aJQpU59fwZ4mxFjqNCgfZgDhONDSYQFMRnYC1dzBpJHzI6b … … 233 150 f4CR5+ba+w2dpuDeM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gGJxFXERBzsBE2YHVda4+e0xCX83UVx9z4pIgsVuUBHp5W/7oGEy9GrP 458 Gp7zUAQA/6gpVXAnsf7BNC6fZQoCBkBMNY/8tCxiKeYsAOmtoM+rFPZYl7ySOzMw 459 NBkIr6OGxWuFl2SLD0QcAzTPsErPokRGYu5MgRyJySRN/NslZdmC/jQG+X33I8yz 460 CdHWVAcPtMrHIdisjt3MlCuLiZs5GDiU6dndPKh2/bU5x/hqzY2jWnp6xlb4zjrO 461 Nl47zPMTGaYQ0jb4/v9VS34tbJAWKpEzSJbMaKhgxaBV4/LAUZpNXnX/S4X3KYcc 462 LsEMhwuBRYd2D/UHruNHlhB/M8lSouGfKW3WyMNFAiV/7dT512+t7ZjFf+thQjaA 463 FPfZDNCu/TXoqyJk7434jJrcHgPryzrHFBLfEmc= 464 =TREp 465 -----END PGP PUBLIC KEY BLOCK----- ", 152 ZXkpIDxpbmZvQHB1cHBldGxhYnMuY29tPokCPgQTAQIAKAUCTDe7QAIbAwUJA8Jn 153 AAYLCQgHAwIGFQgCCQoLBBYCAwECHgECF4AACgkQEFS3okvW7DAZaw//aLmE/eob 154 pXpIUVyCUWQxEvPtM/h/SAJsG3KoHN9u216ews+UHsL/7F91ceVXQQdD2e8CtYWF 155 eLNM0RSM9i/KM60g4CvIQlmNqdqhi1HsgGqInZ72/XLAXun0gabfC36rLww2kel+ 156 aMpRf58SrSuskY321NnMEJl4OsHV2hfNtAIgw2e/zm9RhoMpGKxoHZCvFhnP7u2M 157 2wMq7iNDDWb6dVsLpzdlVf242zCbubPCxxQXOpA56rzkUPuJ85mdVw4i19oPIFIZ 158 VL5owit1SxCOxBg4b8oaMS36hEl3qtZG834rtLfcqAmqjhx6aJuJLOAYN84QjDEU 159 3NI5IfNRMvluIeTcD4Dt5FCYahN045tW1Rc6s5GAR8RW45GYwQDzG+kkkeeGxwEh 160 qCW7nOHuwZIoVJufNhd28UFn83KGJHCQt4NBBr3K5TcY6bDQEIrpSplWSDBbd3p1 161 IaoZ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hml4xlyijgYu05pqNvnLRyJDLd61hviLC8GYU= 194 =a34C 195 -----END PGP PUBLIC KEY BLOCK-----", 466 196 } 467 197 EOS 468 198 469 199 apply_manifest(pp, :catch_failures => true) 470 apply_manifest(pp, :catch_changes => true) 200 apply_manifest(pp, :catch_failures => true) 201 shell(PUPPETLABS_KEY_CHECK_COMMAND) 202 end 203 end 204 205 context 'multiple keys' do 206 it 'runs without errors' do 207 pp = <<-EOS 208 apt_key { 'puppetlabs': 209 id => '#{PUPPETLABS_GPG_KEY_FINGERPRINT}', 210 ensure => 'present', 211 content => "-----BEGIN PGP PUBLIC KEY BLOCK----- 212 Version: GnuPG v1.4.12 (GNU/Linux) 213 Comment: GPGTools - http://gpgtools.org 214 215 mQINBEw3u0ABEAC1+aJQpU59fwZ4mxFjqNCgfZgDhONDSYQFMRnYC1dzBpJHzI6b 216 fUBQeaZ8rh6N4kZ+wq1eL86YDXkCt4sCvNTP0eF2XaOLbmxtV9bdpTIBep9bQiKg 217 5iZaz+brUZlFk/MyJ0Yz//VQ68N1uvXccmD6uxQsVO+gx7rnarg/BGuCNaVtGwy+ 218 S98g8Begwxs9JmGa8pMCcSxtC7fAfAEZ02cYyrw5KfBvFI3cHDdBqrEJQKwKeLKY 219 GHK3+H1TM4ZMxPsLuR/XKCbvTyl+OCPxU2OxPjufAxLlr8BWUzgJv6ztPe9imqpH 220 Ppp3KuLFNorjPqWY5jSgKl94W/CO2x591e++a1PhwUn7iVUwVVe+mOEWnK5+Fd0v 221 VMQebYCXS+3dNf6gxSvhz8etpw20T9Ytg4EdhLvCJRV/pYlqhcq+E9le1jFOHOc0 222 Nc5FQweUtHGaNVyn8S1hvnvWJBMxpXq+Bezfk3X8PhPT/l9O2lLFOOO08jo0OYiI 223 wrjhMQQOOSZOb3vBRvBZNnnxPrcdjUUm/9cVB8VcgI5KFhG7hmMCwH70tpUWcZCN 224 NlI1wj/PJ7Tlxjy44f1o4CQ5FxuozkiITJvh9CTg+k3wEmiaGz65w9jRl9ny2gEl 225 f4CR5+ba+w2dpuDeMwiHJIs5JsGyJjmA5/0xytB7QvgMs2q25vWhygsmUQARAQAB 226 tEdQdXBwZXQgTGFicyBSZWxlYXNlIEtleSAoUHVwcGV0IExhYnMgUmVsZWFzZSBL 227 ZXkpIDxpbmZvQHB1cHBldGxhYnMuY29tPokCPgQTAQIAKAUCTDe7QAIbAwUJA8Jn 228 AAYLCQgHAwIGFQgCCQoLBBYCAwECHgECF4AACgkQEFS3okvW7DAZaw//aLmE/eob 229 pXpIUVyCUWQxEvPtM/h/SAJsG3KoHN9u216ews+UHsL/7F91ceVXQQdD2e8CtYWF 230 eLNM0RSM9i/KM60g4CvIQlmNqdqhi1HsgGqInZ72/XLAXun0gabfC36rLww2kel+ 231 aMpRf58SrSuskY321NnMEJl4OsHV2hfNtAIgw2e/zm9RhoMpGKxoHZCvFhnP7u2M 232 2wMq7iNDDWb6dVsLpzdlVf242zCbubPCxxQXOpA56rzkUPuJ85mdVw4i19oPIFIZ 233 VL5owit1SxCOxBg4b8oaMS36hEl3qtZG834rtLfcqAmqjhx6aJuJLOAYN84QjDEU 234 3NI5IfNRMvluIeTcD4Dt5FCYahN045tW1Rc6s5GAR8RW45GYwQDzG+kkkeeGxwEh 235 qCW7nOHuwZIoVJufNhd28UFn83KGJHCQt4NBBr3K5TcY6bDQEIrpSplWSDBbd3p1 236 IaoZY1WSDdP9OTVOSbsz0JiglWmUWGWCdd/CMSW/D7/3VUOJOYRDwptvtSYcjJc8 237 1UV+1zB+rt5La/OWe4UOORD+jU1ATijQEaFYxBbqBBkFboAEXq9btRQyegqk+eVp 238 HhzacP5NYFTMThvHuTapNytcCso5au/cMywqCgY1DfcMJyjocu4bCtrAd6w4kGKN 239 MUdwNDYQulHZDI+UjJInhramyngdzZLjdeGJARwEEAECAAYFAkw3wEYACgkQIVr+ 240 UOQUcDKvEwgAoBuOPnPioBwYp8oHVPTo/69cJn1225kfraUYGebCcrRwuoKd8Iyh 241 R165nXYJmD8yrAFBk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vnZeo1Q9r7pg+i6uSIu4ywfdNTOuoBK+VY+RKyAybBHIqH07w 370 p9TmYOY1x+wmIe0oSYcR47OcvZU57fdLsEB9djYvkGkkmbz0gwXQL0iEW3kX+05J 371 zrLzPsx6muR35SPNCvfR2T/0VCDwtNwwxACWuZI/tqsobU/+lA/MqRZ4kOD/Bx07 372 CpZfYIAi2STc0MIDvpyDnZLiYVMMkqV4+gn2ANtkF+GKbra3Aeof9b4KEVabSaQ5 373 5W70DJF0G5bmHBSdyqdYnKB/yRj1rH+dgRbiRMv7rBAx5Q8rbYiym8im+5XNUDy2 374 ZTQcCD53HcBLvKX6RJ4ByYawKaQqMa27WK/YWVmFXqVDVk12iKrQW6zktDdGInnD 375 +f0rRH7c/7F/QuBR6Y4Zkso0CuVMNsmxv0E+7Zk0z4dWalzQuXpN7OXcZ8Gp 376 =Gl+v 377 -----END PGP PUBLIC KEY BLOCK-----", 378 } 379 EOS 380 apply_manifest(pp, :catch_failures => true) 381 apply_manifest(pp, :catch_failures => true) 471 382 shell(PUPPETLABS_KEY_CHECK_COMMAND) 472 383 end … … 491 402 492 403 describe 'server =>' do 493 context 'hkps.pool.sks-keyservers.net' do 494 it 'works' do 495 pp = <<-EOS 496 apt_key { 'puppetlabs': 497 id => '#{PUPPETLABS_GPG_KEY_LONG_ID}', 498 ensure => 'present', 499 server => 'hkps.pool.sks-keyservers.net', 500 } 501 EOS 502 503 #Apply the manifest (Retry if timeout error is received from key pool) 504 retry_on_error_matching(MAX_TIMEOUT_RETRY, TIMEOUT_RETRY_WAIT, TIMEOUT_ERROR_MATCHER) do 505 apply_manifest(pp, :catch_failures => true) 506 end 507 508 apply_manifest(pp, :catch_changes => true) 509 shell(PUPPETLABS_KEY_CHECK_COMMAND) 510 end 511 end 512 513 context 'hkp://hkps.pool.sks-keyservers.net:80' do 404 context 'pgp.mit.edu' do 405 it 'works' do 406 pp = <<-EOS 407 apt_key { 'puppetlabs': 408 id => '#{PUPPETLABS_GPG_KEY_LONG_ID}', 409 ensure => 'present', 410 server => 'pgp.mit.edu', 411 } 412 EOS 413 414 apply_manifest(pp, :catch_failures => true) 415 apply_manifest(pp, :catch_failures => true) 416 shell(PUPPETLABS_KEY_CHECK_COMMAND) 417 end 418 end 419 420 context 'hkp://pgp.mit.edu:80' do 514 421 it 'works' do 515 422 pp = <<-EOS … … 517 424 id => '#{PUPPETLABS_GPG_KEY_FINGERPRINT}', 518 425 ensure => 'present', 519 server => 'hkp://hkps.pool.sks-keyservers.net:80', 520 } 521 EOS 522 523 retry_on_error_matching(MAX_TIMEOUT_RETRY, TIMEOUT_RETRY_WAIT, TIMEOUT_ERROR_MATCHER) do 524 apply_manifest(pp, :catch_failures => true) 525 end 526 527 apply_manifest(pp, :catch_changes => true) 426 server => 'hkp://pgp.mit.edu:80', 427 } 428 EOS 429 430 apply_manifest(pp, :catch_failures => true) 431 apply_manifest(pp, :catch_failures => true) 528 432 shell(PUPPETLABS_KEY_CHECK_COMMAND) 529 433 end … … 575 479 576 480 apply_manifest(pp, :catch_failures => true) 577 apply_manifest(pp, :catch_changes => true) 578 shell(PUPPETLABS_KEY_CHECK_COMMAND) 579 end 580 581 it 'works with userinfo' do 582 pp = <<-EOS 583 apt_key { 'puppetlabs': 584 id => '#{PUPPETLABS_GPG_KEY_LONG_ID}', 585 ensure => 'present', 586 source => 'http://dummyuser:dummypassword@#{PUPPETLABS_APT_URL}/#{PUPPETLABS_GPG_KEY_FILE}', 587 } 588 EOS 589 590 apply_manifest(pp, :catch_failures => true) 591 apply_manifest(pp, :catch_changes => true) 481 apply_manifest(pp, :catch_failures => true) 592 482 shell(PUPPETLABS_KEY_CHECK_COMMAND) 593 483 end … … 638 528 639 529 apply_manifest(pp, :catch_failures => true) 640 apply_manifest(pp, :catch_ changes => true)530 apply_manifest(pp, :catch_failures => true) 641 531 shell(CENTOS_KEY_CHECK_COMMAND) 642 532 end … … 682 572 683 573 apply_manifest(pp, :catch_failures => true) 684 apply_manifest(pp, :catch_changes => true) 685 shell(PUPPETLABS_KEY_CHECK_COMMAND) 686 end 687 688 it 'works with userinfo' do 689 pp = <<-EOS 690 apt_key { 'puppetlabs': 691 id => '#{PUPPETLABS_GPG_KEY_LONG_ID}', 692 ensure => 'present', 693 source => 'https://dummyuser:dummypassword@#{PUPPETLABS_APT_URL}/#{PUPPETLABS_GPG_KEY_FILE}', 694 } 695 EOS 696 697 apply_manifest(pp, :catch_failures => true) 698 apply_manifest(pp, :catch_changes => true) 574 apply_manifest(pp, :catch_failures => true) 699 575 shell(PUPPETLABS_KEY_CHECK_COMMAND) 700 576 end … … 742 618 pp = <<-EOS 743 619 apt_key { 'puppetlabs': 744 id => ' EF8D349F',620 id => '4BD6EC30', 745 621 ensure => 'present', 746 622 source => '/tmp/puppetlabs-pubkey.gpg', … … 749 625 750 626 apply_manifest(pp, :catch_failures => true) 751 apply_manifest(pp, :catch_ changes => true)627 apply_manifest(pp, :catch_failures => true) 752 628 shell(PUPPETLABS_KEY_CHECK_COMMAND) 753 629 end … … 806 682 807 683 apply_manifest(pp, :catch_failures => true) 808 apply_manifest(pp, :catch_changes => true) 809 shell(PUPPETLABS_KEY_CHECK_COMMAND) 684 apply_manifest(pp, :catch_failures => true) 685 shell(PUPPETLABS_KEY_CHECK_COMMAND) 686 end 687 688 it 'fails on invalid options' do 689 pp = <<-EOS 690 apt_key { 'puppetlabs': 691 id => '#{PUPPETLABS_GPG_KEY_LONG_ID}', 692 ensure => 'present', 693 options => 'this is totally bonkers', 694 } 695 EOS 696 697 shell("apt-key del #{PUPPETLABS_GPG_KEY_FINGERPRINT}", :acceptable_exit_codes => [0,1,2]) 698 apply_manifest(pp, :expect_failures => true) do |r| 699 expect(r.stderr).to match(/--keyserver-options this is totally/) 700 end 810 701 end 811 702 end … … 824 715 825 716 apply_manifest(pp, :catch_failures => true) 826 apply_manifest(pp, :catch_ changes => true)717 apply_manifest(pp, :catch_failures => true) 827 718 end 828 719 end … … 832 723 pp = <<-EOS 833 724 apt_key { 'puppetlabs': 834 id => ' 6F6B15509CF8E59E6E469F327F438280EF8D9999',725 id => '47B320EB4C7C375AA9DAE1A01054B7A24BD6E666', 835 726 ensure => 'present', 836 727 source => 'https://#{PUPPETLABS_APT_URL}/#{PUPPETLABS_GPG_KEY_FILE}', -
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/apt_spec.rb
rad28f83 rbcf0be5 1 1 require 'spec_helper_acceptance' 2 3 MAX_TIMEOUT_RETRY = 34 TIMEOUT_RETRY_WAIT = 55 TIMEOUT_ERROR_MATCHER = /no valid OpenPGP data found/6 2 7 3 describe 'apt class' do … … 25 21 'repos' => 'main', 26 22 'key' => { 27 'id' => ' 6F6B15509CF8E59E6E469F327F438280EF8D349F',28 'server' => ' hkps.pool.sks-keyservers.net',23 'id' => '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30', 24 'server' => 'pgp.mit.edu', 29 25 }, 30 26 }, … … 34 30 update => { 35 31 'frequency' => 'always', 36 'timeout' => 400,37 'tries' => 3,32 'timeout' => '400', 33 'tries' => '3', 38 34 }, 39 35 purge => { … … 47 43 EOS 48 44 49 #Apply the manifest (Retry if timeout error is received from key pool) 50 retry_on_error_matching(MAX_TIMEOUT_RETRY, TIMEOUT_RETRY_WAIT, TIMEOUT_ERROR_MATCHER) do 51 apply_manifest(pp, :catch_failures => true) 52 end 53 45 apply_manifest(pp, :catch_failures => true) 54 46 apply_manifest(pp, :catch_failures => true) 55 47 end -
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/class_spec.rb
rad28f83 rbcf0be5 12 12 # Run it twice and test for idempotency 13 13 apply_manifest(pp, :catch_failures => true) 14 apply_manifest(pp, :catch_ changes => true)14 apply_manifest(pp, :catch_failures => true) 15 15 end 16 16 end -
src/puppetcode/environments/gnuboat/modules/apt/spec/acceptance/nodesets/default.yml
rad28f83 rbcf0be5 1 1 HOSTS: 2 ubuntu- 1404-x64:2 ubuntu-server-12042-x64: 3 3 roles: 4 - agent5 - default6 platform: ubuntu-14.04-amd647 hypervisor: vagrant8 box: puppetlabs/ubuntu-14.04-64-nocm4 - master 5 platform: ubuntu-server-12.04-amd64 6 box : ubuntu-server-12042-x64-vbox4210-nocm 7 box_url : http://puppet-vagrant-boxes.puppetlabs.com/ubuntu-server-12042-x64-vbox4210-nocm.box 8 hypervisor : vagrant 9 9 CONFIG: 10 10 type: foss 11 vagrant_ssh_port_random: true -
src/puppetcode/environments/gnuboat/modules/apt/spec/classes/apt_backports_spec.rb
rad28f83 rbcf0be5 8 8 let(:facts) do 9 9 { 10 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},11 10 :lsbdistid => 'Debian', 12 11 :osfamily => 'Debian', … … 27 26 let(:facts) do 28 27 { 29 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '6', :full => '6.0' }},30 28 :lsbdistid => 'Debian', 31 29 :osfamily => 'Debian', … … 46 44 let(:facts) do 47 45 { 48 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '14', :full => '14.04' }},49 46 :lsbdistid => 'Ubuntu', 50 47 :osfamily => 'Debian', 51 48 :lsbdistcodename => 'trusty', 52 :lsbdistrelease => '14.04',53 49 :puppetversion => Puppet.version, 54 50 } … … 66 62 let(:facts) do 67 63 { 68 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '14', :full => '14.04' }},69 64 :lsbdistid => 'Ubuntu', 70 65 :osfamily => 'Debian', 71 66 :lsbdistcodename => 'trusty', 72 :lsbdistrelease => '14.04',73 67 :puppetversion => Puppet.version, 74 68 } … … 95 89 let(:facts) do 96 90 { 97 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '14', :full => '14.04' }},98 91 :lsbdistid => 'Ubuntu', 99 92 :osfamily => 'Debian', 100 93 :lsbdistcodename => 'trusty', 101 :lsbdistrelease => '14.04',102 94 :puppetversion => Puppet.version, 103 95 } … … 123 115 let(:facts) do 124 116 { 125 :os => { :family => 'Debian', :name => 'Linuxmint', :release => { :major => '17', :full => '17' }},126 117 :lsbdistid => 'linuxmint', 127 118 :osfamily => 'Debian', … … 208 199 let(:facts) do 209 200 { 210 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '14', :full => '14.04' }},211 201 :lsbdistid => 'Ubuntu', 212 202 :osfamily => 'Debian', 213 203 :lsbdistcodename => 'trusty', 214 :lsbdistrelease => '14.04',215 204 :puppetversion => Puppet.version, 216 205 } … … 225 214 expect { 226 215 subject.call 227 }.to raise_error(Puppet::Error, / expects a/)216 }.to raise_error(Puppet::Error, /is not a string/) 228 217 end 229 218 end … … 237 226 expect { 238 227 subject.call 239 }.to raise_error(Puppet::Error, / expects a/)228 }.to raise_error(Puppet::Error, /is not a string/) 240 229 end 241 230 end … … 249 238 expect { 250 239 subject.call 251 }.to raise_error(Puppet::Error, / expects a/)240 }.to raise_error(Puppet::Error, /is not a string/) 252 241 end 253 242 end … … 261 250 expect { 262 251 subject.call 263 }.to raise_error(Puppet::Error, / expects a/)252 }.to raise_error(Puppet::Error, /is not a string/) 264 253 end 265 254 end … … 273 262 expect { 274 263 subject.call 275 }.to raise_error(Puppet::Error, / expects a/)264 }.to raise_error(Puppet::Error, /pin must be either a string, number or hash/) 276 265 end 277 266 end -
src/puppetcode/environments/gnuboat/modules/apt/spec/classes/apt_spec.rb
rad28f83 rbcf0be5 1 1 require 'spec_helper' 2 2 describe 'apt' do 3 let(:facts) do 4 { 5 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 6 :lsbdistid => 'Debian', 7 :osfamily => 'Debian', 8 :lsbdistcodename => 'wheezy', 9 :puppetversion => Puppet.version, 10 } 11 end 3 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :lsbdistcodename => 'wheezy', :puppetversion => Puppet.version} } 4 12 5 context 'defaults' do 13 6 it { is_expected.to contain_file('sources.list').that_notifies('Class[Apt::Update]').only_with({ … … 145 138 context 'with sources defined on valid osfamily' do 146 139 let :facts do 147 { :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '12', :full => '12.04' }}, 148 :osfamily => 'Debian', 149 :lsbdistcodename => 'precise', 150 :lsbdistid => 'Ubuntu', 151 :lsbdistrelease => '12.04', 140 { :osfamily => 'Debian', 141 :lsbdistcodename => 'precise', 142 :lsbdistid => 'Debian', 152 143 :puppetversion => Puppet.version, 153 144 } … … 165 156 'location' => 'http://apt.puppetlabs.com', 166 157 'repos' => 'main', 167 'key' => { 'id' => ' 6F6B15509CF8E59E6E469F327F438280EF8D349F', 'server' => 'pgp.mit.edu' },158 'key' => { 'id' => '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30', 'server' => 'pgp.mit.edu' }, 168 159 } 169 160 } } } … … 187 178 end 188 179 189 context 'with confs defined on valid osfamily' do190 let :facts do191 {192 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '12', :full => '12.04.5' }},193 :osfamily => 'Debian',194 :lsbdistcodename => 'precise',195 :lsbdistid => 'Debian',196 :puppetversion => Puppet.version,197 }198 end199 let(:params) { { :confs => {200 'foo' => {201 'content' => 'foo',202 },203 'bar' => {204 'content' => 'bar',205 }206 } } }207 208 it { is_expected.to contain_apt__conf('foo').with({209 :content => 'foo',210 })}211 212 it { is_expected.to contain_apt__conf('bar').with({213 :content => 'bar',214 })}215 end216 217 180 context 'with keys defined on valid osfamily' do 218 181 let :facts do 219 { 220 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '12', :full => '12.04.5' }}, 221 :osfamily => 'Debian', 182 { :osfamily => 'Debian', 222 183 :lsbdistcodename => 'precise', 223 184 :lsbdistid => 'Debian', … … 229 190 'server' => 'subkeys.pgp.net', 230 191 }, 231 ' EF8D349F' => {192 '4BD6EC30' => { 232 193 'server' => 'pgp.mit.edu', 233 194 } … … 238 199 })} 239 200 240 it { is_expected.to contain_apt__key(' EF8D349F').with({201 it { is_expected.to contain_apt__key('4BD6EC30').with({ 241 202 :server => 'pgp.mit.edu', 242 203 })} … … 245 206 context 'with ppas defined on valid osfamily' do 246 207 let :facts do 247 { 248 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '12', :full => '12.04.5' }}, 249 :osfamily => 'Debian', 208 { :osfamily => 'Debian', 250 209 :lsbdistcodename => 'precise', 251 210 :lsbdistid => 'ubuntu', … … 265 224 context 'with settings defined on valid osfamily' do 266 225 let :facts do 267 { 268 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '12', :full => '12.04.5' }}, 269 :osfamily => 'Debian', 226 { :osfamily => 'Debian', 270 227 :lsbdistcodename => 'precise', 271 228 :lsbdistid => 'Debian', … … 284 241 context 'with pins defined on valid osfamily' do 285 242 let :facts do 286 { 287 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '12', :full => '12.04.5' }}, 288 :osfamily => 'Debian', 243 { :osfamily => 'Debian', 289 244 :lsbdistcodename => 'precise', 290 245 :lsbdistid => 'Debian', … … 337 292 end 338 293 end 294 295 context 'with unsupported osfamily' do 296 let :facts do 297 { :osfamily => 'Darwin', :puppetversion => Puppet.version,} 298 end 299 300 it do 301 expect { 302 subject.call 303 }.to raise_error(Puppet::Error, /This module only works on Debian or derivatives like Ubuntu/) 304 end 305 end 339 306 end 340 307 end -
src/puppetcode/environments/gnuboat/modules/apt/spec/classes/apt_update_spec.rb
rad28f83 rbcf0be5 4 4 describe 'apt::update', :type => :class do 5 5 context "and apt::update['frequency']='always'" do 6 { 7 'a recent run' => Time.now.to_i, 8 'we are due for a run' => 1406660561, 9 'the update-success-stamp file does not exist' => -1, 10 }.each_pair do |desc, factval| 6 { 'a recent run' => Time.now.to_i, 'we are due for a run' => 1406660561,'the update-success-stamp file does not exist' => -1 }.each_pair do |desc, factval| 11 7 context "and $::apt_update_last_success indicates #{desc}" do 12 let(:facts) { { 13 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 14 :lsbdistid => 'Debian', 15 :osfamily => 'Debian', 16 :apt_update_last_success => factval, 17 :lsbdistcodename => 'wheezy', 18 :puppetversion => Puppet.version, 19 } } 20 let (:pre_condition) { 21 "class{'::apt': update => {'frequency' => 'always' },}" 22 } 8 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :apt_update_last_success => factval, :lsbdistcodename => 'wheezy', :puppetversion => Puppet.version, } } 9 let (:pre_condition) { "class{'::apt': update => {'frequency' => 'always' },}" } 23 10 it 'should trigger an apt-get update run' do 24 11 #set the apt_update exec's refreshonly attribute to false … … 28 15 end 29 16 context 'when $::apt_update_last_success is nil' do 30 let(:facts) { { 31 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 32 :lsbdistid => 'Debian', 33 :osfamily => 'Debian', 34 :lsbdistcodename => 'wheezy', 35 :puppetversion => Puppet.version, 36 } } 17 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :lsbdistcodename => 'wheezy', :puppetversion => Puppet.version, } } 37 18 let (:pre_condition) { "class{ '::apt': update => {'frequency' => 'always' },}" } 38 19 it 'should trigger an apt-get update run' do … … 43 24 end 44 25 context "and apt::update['frequency']='reluctantly'" do 45 { 46 'a recent run' => Time.now.to_i, 47 'we are due for a run' => 1406660561, 48 'the update-success-stamp file does not exist' => -1, 49 }.each_pair do |desc, factval| 26 {'a recent run' => Time.now.to_i, 'we are due for a run' => 1406660561,'the update-success-stamp file does not exist' => -1 }.each_pair do |desc, factval| 50 27 context "and $::apt_update_last_success indicates #{desc}" do 51 let(:facts) { { 52 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 53 :lsbdistid => 'Debian', 54 :osfamily => 'Debian', 55 :apt_update_last_success => factval, 56 :lsbdistcodename => 'wheezy', 57 :puppetversion => Puppet.version, 58 } } 28 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :apt_update_last_success => factval, :lsbdistcodename => 'wheezy', :puppetversion => Puppet.version,} } 59 29 let (:pre_condition) { "class{ '::apt': update => {'frequency' => 'reluctantly' },}" } 60 30 it 'should not trigger an apt-get update run' do … … 65 35 end 66 36 context 'when $::apt_update_last_success is nil' do 67 let(:facts) { { 68 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 69 :lsbdistid => 'Debian', 70 :osfamily => 'Debian', 71 :lsbdistcodename => 'wheezy', 72 :puppetversion => Puppet.version, 73 } } 37 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :lsbdistcodename => 'wheezy', :puppetversion => Puppet.version, } } 74 38 let (:pre_condition) { "class{ '::apt': update => {'frequency' => 'reluctantly' },}" } 75 39 it 'should not trigger an apt-get update run' do … … 83 47 { 'we are due for a run' => 1406660561,'the update-success-stamp file does not exist' => -1 }.each_pair do |desc, factval| 84 48 context "and $::apt_update_last_success indicates #{desc}" do 85 let(:facts) { { 86 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 87 :lsbdistid => 'Debian', 88 :osfamily => 'Debian', 89 :apt_update_last_success => factval, 90 :lsbdistcodename => 'wheezy', 91 :puppetversion => Puppet.version, 92 } } 49 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :apt_update_last_success => factval, :lsbdistcodename => 'wheezy', :puppetversion => Puppet.version, } } 93 50 let (:pre_condition) { "class{ '::apt': update => {'frequency' => '#{update_frequency}',} }" } 94 51 it 'should trigger an apt-get update run' do … … 99 56 end 100 57 context 'when the $::apt_update_last_success fact has a recent value' do 101 let(:facts) { { 102 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 103 :lsbdistid => 'Debian', 104 :osfamily => 'Debian', 105 :lsbdistcodename => 'wheezy', 106 :apt_update_last_success => Time.now.to_i, 107 :puppetversion => Puppet.version, 108 } } 58 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :lsbdistcodename => 'wheezy', :apt_update_last_success => Time.now.to_i, :puppetversion => Puppet.version, } } 109 59 let (:pre_condition) { "class{ '::apt': update => {'frequency' => '#{update_frequency}',} }" } 110 60 it 'should not trigger an apt-get update run' do … … 114 64 end 115 65 context 'when $::apt_update_last_success is nil' do 116 let(:facts) { { 117 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 118 :lsbdistid => 'Debian', 119 :osfamily => 'Debian', 120 :lsbdistcodename => 'wheezy', 121 :apt_update_last_success => nil, 122 :puppetversion => Puppet.version, 123 } } 66 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :lsbdistcodename => 'wheezy', :apt_update_last_success => nil, :puppetversion => Puppet.version, } } 124 67 let (:pre_condition) { "class{ '::apt': update => {'frequency' => '#{update_frequency}',} }" } 125 68 it 'should trigger an apt-get update run' do -
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/conf_spec.rb
rad28f83 rbcf0be5 4 4 'class { "apt": }' 5 5 end 6 let(:facts) { { 7 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 8 :lsbdistid => 'Debian', 9 :osfamily => 'Debian', 10 :lsbdistcodename => 'wheezy', 11 :puppetversion => Puppet.version, 12 } } 6 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :lsbdistcodename => 'wheezy', :puppetversion => Puppet.version, } } 13 7 let :title do 14 8 'norecommends' -
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/key_compat_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'apt::key', :type => :define do 4 let(:facts) { { 5 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 6 :lsbdistid => 'Debian', 7 :osfamily => 'Debian', 8 :puppetversion => Puppet.version, 9 } } 10 GPG_KEY_ID = '6F6B15509CF8E59E6E469F327F438280EF8D349F' 4 let(:facts) { { :lsbdistid => 'Debian' } } 5 GPG_KEY_ID = '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30' 11 6 12 7 let :title do … … 14 9 end 15 10 16 let :pre_condition do17 'include apt'18 end19 20 11 describe 'normal operation' do 21 12 describe 'default options' do 22 it {23 is_expected.tocontain_apt_key(title).with({13 it 'contains the apt_key' do 14 should contain_apt_key(title).with({ 24 15 :id => title, 25 16 :ensure => 'present', 26 17 :source => nil, 27 :server => 'keyserver.ubuntu.com',18 :server => nil, 28 19 :content => nil, 29 }) 30 } 20 :keyserver_options => nil, 21 }) 22 end 31 23 it 'contains the apt_key present anchor' do 32 is_expected.tocontain_anchor("apt_key #{title} present")24 should contain_anchor("apt_key #{title} present") 33 25 end 34 26 end … … 40 32 41 33 let :params do { 42 : id=> GPG_KEY_ID,43 } end 44 45 it 'contains the apt_key' do 46 is_expected.tocontain_apt_key(title).with({34 :key => GPG_KEY_ID, 35 } end 36 37 it 'contains the apt_key' do 38 should contain_apt_key(title).with({ 47 39 :id => GPG_KEY_ID, 48 40 :ensure => 'present', 49 41 :source => nil, 50 :server => 'keyserver.ubuntu.com',42 :server => nil, 51 43 :content => nil, 44 :keyserver_options => nil, 52 45 }) 53 46 end 54 47 it 'contains the apt_key present anchor' do 55 is_expected.tocontain_anchor("apt_key #{GPG_KEY_ID} present")48 should contain_anchor("apt_key #{GPG_KEY_ID} present") 56 49 end 57 50 end … … 63 56 64 57 it 'contains the apt_key' do 65 is_expected.tocontain_apt_key(title).with({58 should contain_apt_key(title).with({ 66 59 :id => title, 67 60 :ensure => 'absent', 68 61 :source => nil, 69 :server => 'keyserver.ubuntu.com',62 :server => nil, 70 63 :content => nil, 64 :keyserver_options => nil, 71 65 }) 72 66 end 73 67 it 'contains the apt_key absent anchor' do 74 is_expected.tocontain_anchor("apt_key #{title} absent")68 should contain_anchor("apt_key #{title} absent") 75 69 end 76 70 end … … 78 72 describe 'set a bunch of things!' do 79 73 let :params do { 80 : content => 'GPG key content',81 : source => 'http://apt.puppetlabs.com/pubkey.gpg',82 : server => 'pgp.mit.edu',83 : options => 'debug',84 } end 85 86 it 'contains the apt_key' do 87 is_expected.tocontain_apt_key(title).with({74 :key_content => 'GPG key content', 75 :key_source => 'http://apt.puppetlabs.com/pubkey.gpg', 76 :key_server => 'pgp.mit.edu', 77 :key_options => 'debug', 78 } end 79 80 it 'contains the apt_key' do 81 should contain_apt_key(title).with({ 88 82 :id => title, 89 83 :ensure => 'present', 90 84 :source => 'http://apt.puppetlabs.com/pubkey.gpg', 91 85 :server => 'pgp.mit.edu', 92 :content => params[: content],86 :content => params[:key_content], 93 87 :options => 'debug', 94 88 }) 95 89 end 96 90 it 'contains the apt_key present anchor' do 97 is_expected.tocontain_anchor("apt_key #{title} present")91 should contain_anchor("apt_key #{title} present") 98 92 end 99 93 end … … 101 95 context "domain with dash" do 102 96 let(:params) do{ 103 : server => 'p-gp.m-it.edu',104 } end 105 it 'contains the apt_key' do 106 is_expected.tocontain_apt_key(title).with({97 :key_server => 'p-gp.m-it.edu', 98 } end 99 it 'contains the apt_key' do 100 should contain_apt_key(title).with({ 107 101 :id => title, 108 102 :server => 'p-gp.m-it.edu', … … 114 108 let :params do 115 109 { 116 : server => 'hkp://pgp.mit.edu',117 } 118 end 119 it 'contains the apt_key' do 120 is_expected.tocontain_apt_key(title).with({110 :key_server => 'hkp://pgp.mit.edu', 111 } 112 end 113 it 'contains the apt_key' do 114 should contain_apt_key(title).with({ 121 115 :id => title, 122 116 :server => 'hkp://pgp.mit.edu', … … 127 121 let :params do 128 122 { 129 : server => 'hkp://pgp.mit.edu:80',130 } 131 end 132 it 'contains the apt_key' do 133 is_expected.tocontain_apt_key(title).with({123 :key_server => 'hkp://pgp.mit.edu:80', 124 } 125 end 126 it 'contains the apt_key' do 127 should contain_apt_key(title).with({ 134 128 :id => title, 135 129 :server => 'hkp://pgp.mit.edu:80', … … 142 136 context "domain begin with dash" do 143 137 let(:params) do{ 144 : server => '-pgp.mit.edu',138 :key_server => '-pgp.mit.edu', 145 139 } end 146 140 it 'fails' do … … 151 145 context "domain begin with dot" do 152 146 let(:params) do{ 153 : server => '.pgp.mit.edu',147 :key_server => '.pgp.mit.edu', 154 148 } end 155 149 it 'fails' do … … 160 154 context "domain end with dot" do 161 155 let(:params) do{ 162 : server => "pgp.mit.edu.",156 :key_server => "pgp.mit.edu.", 163 157 } end 164 158 it 'fails' do … … 169 163 let :params do 170 164 { 171 : server => 'hkp://pgpiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii.mit.edu'165 :key_server => 'hkp://pgpiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii.mit.edu' 172 166 } 173 167 end … … 179 173 let :params do 180 174 { 181 : server => 'hkp://pgp.mit.edu:8008080'175 :key_server => 'hkp://pgp.mit.edu:8008080' 182 176 } 183 177 end … … 189 183 let :params do 190 184 { 191 : server => 'abc://pgp.mit.edu:80'185 :key_server => 'abc://pgp.mit.edu:80' 192 186 } 193 187 end … … 199 193 let :params do 200 194 { 201 : server => 'hkp://pgp.mit.edu:'195 :key_server => 'hkp://pgp.mit.edu:' 202 196 } 203 197 end … … 209 203 let :params do 210 204 { 211 : server => 'hkp://pgp.mit.edu.'205 :key_server => 'hkp://pgp.mit.edu.' 212 206 } 213 207 end … … 218 212 context "url begin with a dash" do 219 213 let(:params) do{ 220 : server => "hkp://-pgp.mit.edu",214 :key_server => "hkp://-pgp.mit.edu", 221 215 } end 222 216 it 'fails' do … … 235 229 context 'invalid source' do 236 230 let :params do { 237 : source => 'afp://puppetlabs.com/key.gpg',231 :key_source => 'afp://puppetlabs.com/key.gpg', 238 232 } end 239 233 it 'fails' do … … 244 238 context 'invalid content' do 245 239 let :params do { 246 : content => [],247 } end 248 it 'fails' do 249 expect { subject.call }.to raise_error(/ expects a/)240 :key_content => [], 241 } end 242 it 'fails' do 243 expect { subject.call }.to raise_error(/is not a string/) 250 244 end 251 245 end … … 253 247 context 'invalid server' do 254 248 let :params do { 255 : server => 'two bottles of rum',249 :key_server => 'two bottles of rum', 256 250 } end 257 251 it 'fails' do … … 262 256 context 'invalid keyserver_options' do 263 257 let :params do { 264 : options => {},265 } end 266 it 'fails' do 267 expect { subject.call }.to raise_error(/ expects a/)258 :key_options => {}, 259 } end 260 it 'fails' do 261 expect { subject.call }.to raise_error(/is not a string/) 268 262 end 269 263 end … … 276 270 end 277 271 it 'fails' do 278 expect { subject.call }.to raise_error(/ Enum\['absent', 'present'\]/)272 expect { subject.call }.to raise_error(/does not match/) 279 273 end 280 274 end … … 283 277 context 'two apt::key resources for same key, different titles' do 284 278 let :pre_condition do 285 " #{super()}\napt::key { 'duplicate': id=> '#{title}', }"286 end 287 288 it 'contains t he duplicate apt::key resource' do289 is_expected.tocontain_apt__key('duplicate').with({290 : id=> title,279 "apt::key { 'duplicate': key => '#{title}', }" 280 end 281 282 it 'contains two apt::key resources' do 283 should contain_apt__key('duplicate').with({ 284 :key => title, 291 285 :ensure => 'present', 292 286 }) 293 end 294 295 it 'contains the original apt::key resource' do 296 is_expected.to contain_apt__key(title).with({ 287 should contain_apt__key(title).with({ 297 288 :id => title, 298 289 :ensure => 'present', … … 300 291 end 301 292 302 it 'contains the native apt_key' do303 is_expected.tocontain_apt_key('duplicate').with({293 it 'contains only a single apt_key' do 294 should contain_apt_key('duplicate').with({ 304 295 :id => title, 305 296 :ensure => 'present', 306 297 :source => nil, 307 :server => 'keyserver.ubuntu.com',298 :server => nil, 308 299 :content => nil, 309 300 :keyserver_options => nil, 310 301 }) 311 end 312 313 it 'does not contain the original apt_key' do 314 is_expected.not_to contain_apt_key(title) 302 should_not contain_apt_key(title) 315 303 end 316 304 end … … 318 306 context 'two apt::key resources, different ensure' do 319 307 let :pre_condition do 320 " #{super()}\napt::key { 'duplicate': id=> '#{title}', ensure => 'absent', }"308 "apt::key { 'duplicate': key => '#{title}', ensure => 'absent', }" 321 309 end 322 310 it 'informs the user of the impossibility' do -
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/key_spec.rb
rad28f83 rbcf0be5 6 6 end 7 7 8 let(:facts) { { 9 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 10 :lsbdistid => 'Debian', 11 :osfamily => 'Debian', 12 :lsbdistcodename => 'wheezy', 13 :puppetversion => Puppet.version, 14 } } 15 16 GPG_KEY_ID = '6F6B15509CF8E59E6E469F327F438280EF8D349F' 8 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :lsbdistcodename => 'wheezy', :puppetversion => Puppet.version, } } 9 10 GPG_KEY_ID = '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30' 17 11 18 12 let :title do … … 252 246 } end 253 247 it 'fails' do 254 expect { subject.call }.to raise_error(/ expects a/)248 expect { subject.call }.to raise_error(/is not a string/) 255 249 end 256 250 end … … 270 264 } end 271 265 it 'fails' do 272 expect { subject.call }.to raise_error(/ expects a/)266 expect { subject.call }.to raise_error(/is not a string/) 273 267 end 274 268 end 275 269 276 270 context 'invalid ensure' do 277 %w(foo aabsent absenta apresent presenta).each do |param| 278 let :params do 279 { 280 :ensure => param, 281 } 282 end 283 it 'fails' do 284 expect { subject.call }.to raise_error(/for Enum\['absent', 'present'\], got/) 285 end 271 let :params do 272 { 273 :ensure => 'foo', 274 } 275 end 276 it 'fails' do 277 expect { subject.call }.to raise_error(/does not match/) 286 278 end 287 279 end -
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/pin_spec.rb
rad28f83 rbcf0be5 4 4 'class { "apt": }' 5 5 end 6 let(:facts) { { 7 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 8 :lsbdistid => 'Debian', 9 :osfamily => 'Debian', 10 :lsbdistcodename => 'wheezy', 11 :puppetversion => Puppet.version, 12 } } 6 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :lsbdistcodename => 'wheezy', :puppetversion => Puppet.version, } } 13 7 let(:title) { 'my_pin' } 14 8 15 9 context 'defaults' do 16 10 it { is_expected.to contain_apt__setting("pref-my_pin").with_content(/Explanation: : my_pin\nPackage: \*\nPin: release a=my_pin\nPin-Priority: 0\n/)} 11 it { is_expected.to contain_apt__setting("pref-my_pin") } 17 12 end 18 13 … … 21 16 { 22 17 'packages' => 'vim', 23 'version' => "1",18 'version' => '1', 24 19 } 25 20 end 26 21 it { is_expected.to contain_apt__setting("pref-my_pin").with_content(/Explanation: : my_pin\nPackage: vim\nPin: version 1\nPin-Priority: 0\n/)} 22 it { is_expected.to contain_apt__setting("pref-my_pin") } 27 23 end 28 24 … … 35 31 end 36 32 it { is_expected.to contain_apt__setting("pref-my_pin").with_content(/Explanation: : my_pin\nPackage: vim\nPin: origin test\nPin-Priority: 0\n/)} 33 it { is_expected.to contain_apt__setting("pref-my_pin") } 37 34 end 38 35 … … 85 82 expect { 86 83 subject.call 87 }.to raise_error(Puppet::Error, / expects an Integer value, got String/)84 }.to raise_error(Puppet::Error, /Only integers are allowed/) 88 85 end 89 86 end -
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/ppa_spec.rb
rad28f83 rbcf0be5 8 8 let :facts do 9 9 { 10 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '11', :full => '11.04' }},11 10 :lsbdistrelease => '11.04', 12 11 :lsbdistcodename => 'natty', … … 23 22 :environment => [], 24 23 :command => '/usr/bin/add-apt-repository -y ppa:needs/such.substitution/wow+type', 25 :unless => '/usr/bin/test - f/etc/apt/sources.list.d/needs-such_substitution-wow_type-natty.list',24 :unless => '/usr/bin/test -s /etc/apt/sources.list.d/needs-such_substitution-wow_type-natty.list', 26 25 :user => 'root', 27 26 :logoutput => 'on_failure', … … 33 32 let :facts do 34 33 { 35 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '15', :full => '15.10' }},36 34 :lsbdistrelease => '15.10', 37 35 :lsbdistcodename => 'wily', … … 47 45 :environment => [], 48 46 :command => '/usr/bin/add-apt-repository -y ppa:user/foo', 49 :unless => '/usr/bin/test - f/etc/apt/sources.list.d/user-ubuntu-foo-wily.list',47 :unless => '/usr/bin/test -s /etc/apt/sources.list.d/user-ubuntu-foo-wily.list', 50 48 :user => 'root', 51 49 :logoutput => 'on_failure', … … 72 70 let :facts do 73 71 { 74 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '11', :full => '11.04' }},75 72 :lsbdistrelease => '11.04', 76 73 :lsbdistcodename => 'natty', … … 87 84 'environment' => [], 88 85 'command' => '/usr/bin/add-apt-repository -y ppa:needs/such.substitution/wow', 89 'unless' => '/usr/bin/test - f/etc/apt/sources.list.d/needs-such_substitution-wow-natty.list',86 'unless' => '/usr/bin/test -s /etc/apt/sources.list.d/needs-such_substitution-wow-natty.list', 90 87 'user' => 'root', 91 88 'logoutput' => 'on_failure', … … 108 105 let :facts do 109 106 { 110 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '11', :full => '11.04' }},111 107 :lsbdistrelease => '11.04', 112 108 :lsbdistcodename => 'natty', … … 128 124 'environment' => [], 129 125 'command' => '/usr/bin/add-apt-repository -y ppa:user/bar', 130 'unless' => '/usr/bin/test - f/etc/apt/sources.list.d/user-bar-natty.list',126 'unless' => '/usr/bin/test -s /etc/apt/sources.list.d/user-bar-natty.list', 131 127 'user' => 'root', 132 128 'logoutput' => 'on_failure', … … 146 142 let :facts do 147 143 { 148 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '11', :full => '11.04' }},149 144 :lsbdistrelease => '11.04', 150 145 :lsbdistcodename => 'natty', … … 166 161 'environment' => [], 167 162 'command' => '/usr/bin/add-apt-repository -y ppa:needs/such.substitution/wow', 168 'unless' => '/usr/bin/test - f/etc/apt/sources.list.d/needs-such_substitution-wow-natty.list',163 'unless' => '/usr/bin/test -s /etc/apt/sources.list.d/needs-such_substitution-wow-natty.list', 169 164 'user' => 'root', 170 165 'logoutput' => 'on_failure', … … 186 181 let :facts do 187 182 { 188 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '14', :full => '14.04' }},189 183 :lsbdistrelease => '14.04', 190 184 :lsbdistcodename => 'trusty', … … 208 202 :environment => [], 209 203 :command => '/usr/bin/add-apt-repository ppa:user/foo', 210 :unless => '/usr/bin/test - f/etc/apt/sources.list.d/user-foo-trusty.list',204 :unless => '/usr/bin/test -s /etc/apt/sources.list.d/user-foo-trusty.list', 211 205 :user => 'root', 212 206 :logoutput => 'on_failure', … … 223 217 let :facts do 224 218 { 225 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '14', :full => '14.04' }},226 219 :lsbdistrelease => '14.04', 227 220 :lsbdistcodename => 'trusty', … … 243 236 :environment => ['http_proxy=http://localhost:8080'], 244 237 :command => '/usr/bin/add-apt-repository ppa:user/foo', 245 :unless => '/usr/bin/test - f/etc/apt/sources.list.d/user-foo-trusty.list',238 :unless => '/usr/bin/test -s /etc/apt/sources.list.d/user-foo-trusty.list', 246 239 :user => 'root', 247 240 :logoutput => 'on_failure', … … 258 251 let :facts do 259 252 { 260 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '14', :full => '14.04' }},261 253 :lsbdistrelease => '14.04', 262 254 :lsbdistcodename => 'trusty', … … 278 270 :environment => ['http_proxy=http://localhost:8180'], 279 271 :command => '/usr/bin/add-apt-repository ppa:user/foo', 280 :unless => '/usr/bin/test - f/etc/apt/sources.list.d/user-foo-trusty.list',272 :unless => '/usr/bin/test -s /etc/apt/sources.list.d/user-foo-trusty.list', 281 273 :user => 'root', 282 274 :logoutput => 'on_failure', … … 293 285 let :facts do 294 286 { 295 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '14', :full => '14.04' }},296 287 :lsbdistrelease => '14.04', 297 288 :lsbdistcodename => 'trusty', … … 313 304 :environment => ['http_proxy=http://localhost:8180', 'https_proxy=https://localhost:8180'], 314 305 :command => '/usr/bin/add-apt-repository ppa:user/foo', 315 :unless => '/usr/bin/test - f/etc/apt/sources.list.d/user-foo-trusty.list',306 :unless => '/usr/bin/test -s /etc/apt/sources.list.d/user-foo-trusty.list', 316 307 :user => 'root', 317 308 :logoutput => 'on_failure', … … 326 317 let :facts do 327 318 { 328 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '14', :full => '14.04' }},329 319 :lsbdistrelease => '14.04', 330 320 :lsbdistcodename => 'trusty', … … 351 341 let :facts do 352 342 { 353 :os => { :family => 'Debian', :name => 'Ubuntu', :release => { :major => '14', :full => '14.04' }},354 343 :lsbdistrelease => '14.04', 355 344 :operatingsystem => 'Ubuntu', … … 371 360 let :facts do 372 361 { 373 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '6', :full => '6.0.7' }},374 362 :lsbdistrelease => '6.0.7', 375 363 :lsbdistcodename => 'wheezy', -
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/setting_spec.rb
rad28f83 rbcf0be5 3 3 describe 'apt::setting' do 4 4 let(:pre_condition) { 'class { "apt": }' } 5 let :facts do 6 { 7 :os => { :distro => { :codename => 'wheezy' }, :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 8 :lsbdistrelease => '7.0', 9 :lsbdistcodename => 'wheezy', 10 :operatingsystem => 'Debian', 11 :osfamily => 'Debian', 12 :lsbdistid => 'Debian', 13 :puppetversion => Puppet.version, 14 } 15 end 5 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :lsbdistcodename => 'wheezy', :puppetversion => Puppet.version, } } 16 6 let(:title) { 'conf-teddybear' } 17 7 … … 72 62 ' 73 63 end 74 let(:facts) { { 75 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 76 :lsbdistid => 'Debian', 77 :osfamily => 'Debian', 78 :lsbdistcodename => 'wheezy', 79 :puppetversion => Puppet.version, 80 } } 64 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian', :lsbdistcodename => 'wheezy', :puppetversion => Puppet.version, } } 81 65 let(:title) { 'conf-teddybear' } 82 66 let(:default_params) { { :content => 'di' } } … … 99 83 let(:params) { default_params } 100 84 it do 101 expect { subject.call }.to raise_error(Puppet::Error, /must start with either/)85 expect { subject.call }.to raise_error(Puppet::Error, /must start with /) 102 86 end 103 87 end … … 106 90 let(:params) { default_params.merge({ :ensure => 'banana' }) } 107 91 it do 108 expect { subject.call }.to raise_error(Puppet::Error, / Enum\['absent', 'file', 'present'\]/)92 expect { subject.call }.to raise_error(Puppet::Error, /"banana" does not /) 109 93 end 110 94 end … … 112 96 context 'with priority=1.2' do 113 97 let(:params) { default_params.merge({ :priority => 1.2 }) } 114 if Puppet::Util::Package.versioncmp(Puppet.version, '4.0') >= 0 || ENV["FUTURE_PARSER"] == 'yes' 115 it { is_expected.to compile.and_raise_error(/expects a value of type/) } 116 else 117 it { is_expected.to compile.and_raise_error(/priority must be an integer or a zero-padded integer/) } 98 it do 99 expect { subject.call }.to raise_error(Puppet::Error, /be an integer /) 118 100 end 119 101 end -
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/source_compat_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'apt::source', :type => :define do 4 GPG_KEY_ID = ' 6F6B15509CF8E59E6E469F327F438280EF8D349F'4 GPG_KEY_ID = '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30' 5 5 6 6 let :title do … … 11 11 let :facts do 12 12 { 13 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},14 13 :lsbdistid => 'Debian', 15 14 :lsbdistcodename => 'wheezy', 16 15 :osfamily => 'Debian', 17 :puppetversion => Puppet.version,18 16 } 19 17 end … … 21 19 let :params do 22 20 { 23 'include' => { 'deb' => false, 'src' => true }, 21 'include_deb' => false, 22 'include_src' => true, 24 23 'location' => 'http://debian.mirror.iweb.ca/debian/', 25 24 } … … 33 32 let :facts do 34 33 { 35 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},36 34 :lsbdistid => 'Debian', 37 35 :lsbdistcodename => 'wheezy', 38 :osfamily => 'Debian', 39 :puppetversion => Puppet.version, 36 :osfamily => 'Debian' 40 37 } 41 38 end 42 39 let :params do 43 40 { 44 'comment' => 'foo', 45 'location' => 'http://debian.mirror.iweb.ca/debian/', 46 'release' => 'sid', 47 'repos' => 'testing', 48 'include' => { 'src' => false }, 49 'key' => GPG_KEY_ID, 50 'pin' => '10', 51 'architecture' => 'x86_64', 52 'allow_unsigned' => true, 41 'comment' => 'foo', 42 'location' => 'http://debian.mirror.iweb.ca/debian/', 43 'release' => 'sid', 44 'repos' => 'testing', 45 'include_src' => false, 46 'required_packages' => 'vim', 47 'key' => GPG_KEY_ID, 48 'key_server' => 'pgp.mit.edu', 49 'key_content' => 'GPG key content', 50 'key_source' => 'http://apt.puppetlabs.com/pubkey.gpg', 51 'pin' => '10', 52 'architecture' => 'x86_64', 53 'trusted_source' => true, 53 54 } 54 55 end … … 64 65 } 65 66 67 it { is_expected.to contain_exec("Required packages: 'vim' for my_source").that_comes_before('Apt::Setting[list-my_source]').with({ 68 'command' => '/usr/bin/apt-get -y install vim', 69 'logoutput' => 'on_failure', 70 'refreshonly' => true, 71 'tries' => '3', 72 'try_sleep' => '1', 73 }) 74 } 75 66 76 it { is_expected.to contain_apt__key("Add key: #{GPG_KEY_ID} from Apt::Source my_source").that_comes_before('Apt::Setting[list-my_source]').with({ 67 77 'ensure' => 'present', 68 78 'id' => GPG_KEY_ID, 79 'key_server' => 'pgp.mit.edu', 80 'key_content' => 'GPG key content', 81 'key_source' => 'http://apt.puppetlabs.com/pubkey.gpg', 69 82 }) 70 83 } 71 84 end 72 85 73 context ' allow_unsignedtrue' do86 context 'trusted_source true' do 74 87 let :facts do 75 88 { 76 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},77 89 :lsbdistid => 'Debian', 78 90 :lsbdistcodename => 'wheezy', 79 :osfamily => 'Debian', 80 :puppetversion => Puppet.version, 91 :osfamily => 'Debian' 81 92 } 82 93 end 83 94 let :params do 84 95 { 85 'include ' => {'src' => false},96 'include_src' => false, 86 97 'location' => 'http://debian.mirror.iweb.ca/debian/', 87 ' allow_unsigned' => true,98 'trusted_source' => true, 88 99 } 89 100 end … … 95 106 let :facts do 96 107 { 97 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},98 108 :lsbdistid => 'Debian', 99 109 :lsbdistcodename => 'wheezy', 100 :osfamily => 'Debian', 101 :puppetversion => Puppet.version, 110 :osfamily => 'Debian' 102 111 } 103 112 end … … 116 125 let :facts do 117 126 { 118 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},119 127 :lsbdistid => 'Debian', 120 128 :lsbdistcodename => 'wheezy', 121 :osfamily => 'Debian', 122 :puppetversion => Puppet.version, 129 :osfamily => 'Debian' 123 130 } 124 131 end … … 139 146 let :facts do 140 147 { 141 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},142 148 :lsbdistid => 'Debian', 143 :osfamily => 'Debian', 144 :puppetversion => Puppet.version, 149 :osfamily => 'Debian' 145 150 } 146 151 end -
src/puppetcode/environments/gnuboat/modules/apt/spec/defines/source_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'apt::source' do 4 GPG_KEY_ID = ' 6F6B15509CF8E59E6E469F327F438280EF8D349F'4 GPG_KEY_ID = '47B320EB4C7C375AA9DAE1A01054B7A24BD6EC30' 5 5 6 6 let :pre_condition do … … 16 16 let :facts do 17 17 { 18 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 18 :lsbdistid => 'Debian', 19 :lsbdistcodename => 'wheezy', 19 20 :osfamily => 'Debian', 20 :lsbdistcodename => 'wheezy',21 21 :puppetversion => Puppet.version, 22 22 } … … 31 31 let :facts do 32 32 { 33 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},34 33 :lsbdistid => 'Debian', 35 34 :lsbdistcodename => 'wheezy', … … 50 49 let :facts do 51 50 { 52 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 53 :lsbdistid => 'Debian', 54 :lsbdistcodename => 'wheezy', 55 :osfamily => 'Debian', 56 :operatingsystem => 'Debian', 57 :lsbdistrelease => '7.0', 51 :lsbdistid => 'Debian', 52 :lsbdistcodename => 'wheezy', 53 :osfamily => 'Debian', 58 54 :puppetversion => Puppet.version, 59 55 } … … 194 190 let :facts do 195 191 { 196 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},197 192 :lsbdistid => 'Debian', 198 193 :lsbdistcodename => 'wheezy', … … 217 212 let :facts do 218 213 { 219 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},220 214 :lsbdistid => 'Debian', 221 215 :lsbdistcodename => 'wheezy', … … 227 221 { 228 222 :location => 'hello.there', 229 :include => {'deb' => false, 'src' => true },223 :include => {'deb' => false, 'src' => true,}, 230 224 :architecture => 'x86_64', 231 225 } … … 238 232 end 239 233 240 context 'with architecture fact and unset architecture parameter' do241 let :facts do242 {243 :architecture => 'amd64',244 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},245 :lsbdistid => 'Debian',246 :lsbdistcodename => 'wheezy',247 :osfamily => 'Debian',248 :puppetversion => Puppet.version,249 }250 end251 let :params do252 {253 :location => 'hello.there',254 :include => {'deb' => false, 'src' => true,},255 }256 end257 258 it { is_expected.to contain_apt__setting('list-my_source').with({259 :ensure => 'present',260 }).with_content(/# my_source\ndeb-src hello.there wheezy main\n/)261 }262 end263 264 234 context 'include_src => true' do 265 235 let :facts do 266 236 { 267 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},268 237 :lsbdistid => 'Debian', 269 238 :lsbdistcodename => 'wheezy', … … 275 244 { 276 245 :location => 'hello.there', 277 :include => {'src' => true},246 :include_src => true, 278 247 } 279 248 end … … 285 254 end 286 255 287 context 'include deb => false' do 288 let :facts do 289 { 290 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 256 context 'include_deb => false' do 257 let :facts do 258 { 291 259 :lsbdistid => 'debian', 292 260 :lsbdistcodename => 'wheezy', … … 297 265 let :params do 298 266 { 299 :include => { 'deb' => false },300 267 :location => 'hello.there', 268 :include_deb => false, 301 269 } 302 270 end … … 309 277 end 310 278 311 context 'include src => true and include deb => false' do 312 let :facts do 313 { 314 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }}, 279 context 'include_src => true and include_deb => false' do 280 let :facts do 281 { 315 282 :lsbdistid => 'debian', 316 283 :lsbdistcodename => 'wheezy', … … 321 288 let :params do 322 289 { 323 :include => { 'deb' => false, 'src' => true },324 290 :location => 'hello.there', 291 :include_deb => false, 292 :include_src => true, 325 293 } 326 294 end … … 333 301 end 334 302 303 context 'include precedence' do 304 let :facts do 305 { 306 :lsbdistid => 'debian', 307 :lsbdistcodename => 'wheezy', 308 :osfamily => 'debian', 309 :puppetversion => Puppet.version, 310 } 311 end 312 let :params do 313 { 314 :location => 'hello.there', 315 :include_deb => true, 316 :include_src => false, 317 :include => { 'deb' => false, 'src' => true }, 318 } 319 end 320 321 it { is_expected.to contain_apt__setting('list-my_source').with({ 322 :ensure => 'present', 323 }).with_content(/deb-src hello.there wheezy main\n/) 324 } 325 it { is_expected.to contain_apt__setting('list-my_source').without_content(/deb hello.there wheezy main\n/) } 326 end 327 335 328 context 'ensure => absent' do 336 329 let :facts do 337 330 { 338 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},339 331 :lsbdistid => 'Debian', 340 332 :lsbdistcodename => 'wheezy', … … 359 351 let :facts do 360 352 { 361 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},362 353 :lsbdistid => 'Debian', 363 354 :osfamily => 'Debian', … … 374 365 end 375 366 376 context 'release is empty string' do377 let :facts do378 {379 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},380 :lsbdistid => 'Debian',381 :osfamily => 'Debian',382 :puppetversion => Puppet.version,383 }384 end385 let(:params) { { :location => 'hello.there', :release => '' } }386 387 it { is_expected.to contain_apt__setting('list-my_source').with_content(/hello\.there main/) }388 end389 390 367 context 'invalid pin' do 391 368 let :facts do 392 369 { 393 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},394 370 :lsbdistid => 'Debian', 395 371 :lsbdistcodename => 'wheezy', … … 412 388 end 413 389 414 context "with notify_update = undef (default)" do415 let :facts do416 {417 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},418 :lsbdistid => 'Debian',419 :lsbdistcodename => 'wheezy',420 :osfamily => 'Debian',421 :puppetversion => Puppet.version,422 }423 end424 let :params do425 {426 :location => 'hello.there',427 }428 end429 it { is_expected.to contain_apt__setting("list-#{title}").with_notify_update(true) }430 end431 432 context "with notify_update = true" do433 let :facts do434 {435 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},436 :lsbdistid => 'Debian',437 :lsbdistcodename => 'wheezy',438 :osfamily => 'Debian',439 :puppetversion => Puppet.version,440 }441 end442 let :params do443 {444 :location => 'hello.there',445 :notify_update => true,446 }447 end448 it { is_expected.to contain_apt__setting("list-#{title}").with_notify_update(true) }449 end450 451 context "with notify_update = false" do452 let :facts do453 {454 :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '7', :full => '7.0' }},455 :lsbdistid => 'Debian',456 :lsbdistcodename => 'wheezy',457 :osfamily => 'Debian',458 :puppetversion => Puppet.version,459 }460 end461 let :params do462 {463 :location => 'hello.there',464 :notify_update => false,465 }466 end467 it { is_expected.to contain_apt__setting("list-#{title}").with_notify_update(false) }468 end469 470 390 end 471 391 end -
src/puppetcode/environments/gnuboat/modules/apt/spec/spec_helper_acceptance.rb
rad28f83 rbcf0be5 1 1 require 'beaker-rspec' 2 2 require 'beaker/puppet_install_helper' 3 require 'beaker/module_install_helper'4 3 5 4 run_puppet_install_helper 6 install_module_on(hosts)7 install_module_dependencies_on(hosts)8 5 9 6 UNSUPPORTED_PLATFORMS = ['RedHat','Suse','windows','AIX','Solaris'] 10 11 # This method allows a block to be passed in and if an exception is raised12 # that matches the 'error_matcher' matcher, the block will wait a set number13 # of seconds before retrying.14 # Params:15 # - max_retry_count - Max number of retries16 # - retry_wait_interval_secs - Number of seconds to wait before retry17 # - error_matcher - Matcher which the exception raised must match to allow retry18 # Example Usage:19 # retry_on_error_matching(3, 5, /OpenGPG Error/) do20 # apply_manifest(pp, :catch_failures => true)21 # end22 def retry_on_error_matching(max_retry_count = 3, retry_wait_interval_secs = 5, error_matcher = nil)23 try = 024 begin25 try += 126 yield27 rescue Exception => e28 if try < max_retry_count && (error_matcher == nil || e.message =~ error_matcher)29 sleep retry_wait_interval_secs30 retry31 else32 raise33 end34 end35 end36 7 37 8 RSpec.configure do |c| … … 41 12 # Readable test descriptions 42 13 c.formatter = :documentation 14 15 # Configure all nodes in nodeset 16 c.before :suite do 17 # Install module and dependencies 18 hosts.each do |host| 19 copy_module_to(host, :source => proj_root, :module_name => 'apt') 20 shell("/bin/touch #{default['puppetpath']}/hiera.yaml") 21 on host, puppet('module install puppetlabs-stdlib --version 4.5.0'), { :acceptable_exit_codes => [0,1] } 22 end 23 end 43 24 end -
src/puppetcode/environments/gnuboat/modules/apt/spec/unit/facter/apt_has_updates_spec.rb
rad28f83 rbcf0be5 12 12 end 13 13 14 describe 'on Debian based distro missing apt-get' do14 describe 'on Debian based distro missing update-notifier-common' do 15 15 before { 16 16 Facter.fact(:osfamily).expects(:value).at_least(1).returns 'Debian' 17 17 File.stubs(:executable?) # Stub all other calls 18 File.expects(:executable?).with('/usr/bin/apt-get').returns false 18 File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns false 19 } 20 it { is_expected.to be_nil } 21 end 22 23 describe 'on Debian based distro with broken packages' do 24 before { 25 Facter.fact(:osfamily).expects(:value).at_least(1).returns 'Debian' 26 File.stubs(:executable?) # Stub all other calls 27 Facter::Util::Resolution.stubs(:exec) # Catch all other calls 28 File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true 29 Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>&1').returns "E: Error: BrokenCount > 0" 30 } 31 it { is_expected.to be_nil } 32 end 33 34 describe 'on Debian based distro with unknown error with semicolons' do 35 before { 36 Facter.fact(:osfamily).expects(:value).at_least(1).returns 'Debian' 37 File.stubs(:executable?) # Stub all other calls 38 Facter::Util::Resolution.stubs(:exec) # Catch all other calls 39 File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true 40 Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>&1').returns "E: Unknown Error: 'This error contains something that could be parsed like 4;3' (10)" 19 41 } 20 42 it { is_expected.to be_nil } … … 26 48 File.stubs(:executable?) # Stub all other calls 27 49 Facter::Util::Resolution.stubs(:exec) # Catch all other calls 28 File.expects(:executable?).with('/usr/bin/apt-get').returns true 29 Facter::Util::Resolution.expects(:exec).with('/usr/bin/apt-get -s upgrade 2>&1').returns ""+ 30 "Inst tzdata [2015f-0+deb8u1] (2015g-0+deb8u1 Debian:stable-updates [all])\n"+ 31 "Conf tzdata (2015g-0+deb8u1 Debian:stable-updates [all])\n"+ 32 "Inst unhide.rb [13-1.1] (22-2~bpo8+1 Debian Backports:jessie-backports [all])\n"+ 33 "Conf unhide.rb (22-2~bpo8+1 Debian Backports:jessie-backports [all])\n" 50 File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true 51 Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>&1').returns "4;3" 34 52 } 35 53 it { is_expected.to be true } -
src/puppetcode/environments/gnuboat/modules/apt/spec/unit/facter/apt_package_updates_spec.rb
rad28f83 rbcf0be5 17 17 File.stubs(:executable?) # Stub all other calls 18 18 Facter::Util::Resolution.stubs(:exec) # Catch all other calls 19 File.expects(:executable?).with('/usr/bin/apt-get').returns true 20 Facter::Util::Resolution.expects(:exec).with('/usr/bin/apt-get -s upgrade 2>&1').returns ""+ 21 "Inst tzdata [2015f-0+deb8u1] (2015g-0+deb8u1 Debian:stable-updates [all])\n"+ 22 "Conf tzdata (2015g-0+deb8u1 Debian:stable-updates [all])\n"+ 23 "Inst unhide.rb [13-1.1] (22-2~bpo8+1 Debian Backports:jessie-backports [all])\n"+ 24 "Conf unhide.rb (22-2~bpo8+1 Debian Backports:jessie-backports [all])\n" 19 File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true 20 Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>&1').returns "1;2" 21 Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check -p 2>&1').returns "puppet-common\nlinux-generic\nlinux-image-generic" 25 22 } 26 23 it { 27 24 if Facter.version < '2.0.0' 28 is_expected.to eq(' tzdata,unhide.rb')25 is_expected.to eq('puppet-common,linux-generic,linux-image-generic') 29 26 else 30 is_expected.to eq([' tzdata','unhide.rb'])27 is_expected.to eq(['puppet-common', 'linux-generic', 'linux-image-generic']) 31 28 end 32 29 } -
src/puppetcode/environments/gnuboat/modules/apt/spec/unit/facter/apt_security_updates_spec.rb
rad28f83 rbcf0be5 17 17 File.stubs(:executable?) # Stub all other calls 18 18 Facter::Util::Resolution.stubs(:exec) # Catch all other calls 19 File.expects(:executable?).with('/usr/bin/apt-get').returns true 20 Facter::Util::Resolution.expects(:exec).with('/usr/bin/apt-get -s upgrade 2>&1').returns ""+ 21 "Inst tzdata [2015f-0+deb8u1] (2015g-0+deb8u1 Debian:stable-updates [all])\n"+ 22 "Conf tzdata (2015g-0+deb8u1 Debian:stable-updates [all])\n"+ 23 "Inst unhide.rb [13-1.1] (22-2~bpo8+1 Debian Backports:jessie-backports [all])\n"+ 24 "Conf unhide.rb (22-2~bpo8+1 Debian Backports:jessie-backports [all])\n" 19 File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true 20 Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>&1').returns "14;7" 25 21 } 26 it { is_expected.to eq( 1) }22 it { is_expected.to eq(7) } 27 23 end 28 24 -
src/puppetcode/environments/gnuboat/modules/apt/spec/unit/facter/apt_update_last_success_spec.rb
rad28f83 rbcf0be5 3 3 describe 'apt_update_last_success fact' do 4 4 subject { Facter.fact(:apt_update_last_success).value } 5 before(:each) { Facter.clear }6 5 after(:each) { Facter.clear } 7 6 8 7 describe 'on Debian based distro which has not yet created the update-success-stamp file' do 8 before { 9 Facter.fact(:osfamily).stubs(:value).returns 'Debian' 10 File.stubs(:exists?).returns false 11 } 9 12 it 'should have a value of -1' do 10 Facter.fact(:osfamily).stubs(:value).returns 'Debian'11 File.expects(:exists?).with('/var/lib/apt/periodic/update-success-stamp').returns false12 13 is_expected.to eq(-1) 13 14 end … … 15 16 16 17 describe 'on Debian based distro which has created the update-success-stamp' do 17 it 'should have the value of the mtime of the file' do18 before { 18 19 Facter.fact(:osfamily).stubs(:value).returns 'Debian' 19 20 File.stubs(:exists?).returns true 20 21 File.stubs(:mtime).returns 1407660561 22 } 23 it 'should have the value of the mtime of the file' do 21 24 is_expected.to eq(1407660561) 22 25 end -
src/puppetcode/environments/gnuboat/modules/apt/spec/unit/facter/apt_updates_spec.rb
rad28f83 rbcf0be5 17 17 File.stubs(:executable?) # Stub all other calls 18 18 Facter::Util::Resolution.stubs(:exec) # Catch all other calls 19 File.expects(:executable?).with('/usr/bin/apt-get').returns true 20 Facter::Util::Resolution.expects(:exec).with('/usr/bin/apt-get -s upgrade 2>&1').returns ""+ 21 "Inst tzdata [2015f-0+deb8u1] (2015g-0+deb8u1 Debian:stable-updates [all])\n"+ 22 "Conf tzdata (2015g-0+deb8u1 Debian:stable-updates [all])\n"+ 23 "Inst unhide.rb [13-1.1] (22-2~bpo8+1 Debian Backports:jessie-backports [all])\n"+ 24 "Conf unhide.rb (22-2~bpo8+1 Debian Backports:jessie-backports [all])\n" 19 File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true 20 Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>&1').returns "14;7" 25 21 } 26 it { is_expected.to eq( 2) }22 it { is_expected.to eq(14) } 27 23 end 28 24 -
src/puppetcode/environments/gnuboat/modules/apt/spec/unit/puppet/type/apt_key_spec.rb
rad28f83 rbcf0be5 5 5 context 'only namevar 32bit key id' do 6 6 let(:resource) { Puppet::Type.type(:apt_key).new( 7 :id => ' EF8D349F'7 :id => '4BD6EC30' 8 8 )} 9 9 it 'id is set' do 10 expect(resource[:id]).to eq ' EF8D349F'10 expect(resource[:id]).to eq '4BD6EC30' 11 11 end 12 12 13 13 it 'name is set to id' do 14 expect(resource[:name]).to eq ' EF8D349F'14 expect(resource[:name]).to eq '4BD6EC30' 15 15 end 16 16 … … 30 30 context 'with a lowercase 32bit key id' do 31 31 let(:resource) { Puppet::Type.type(:apt_key).new( 32 :id => ' ef8d349f'32 :id => '4bd6ec30' 33 33 )} 34 34 it 'id is set' do 35 expect(resource[:id]).to eq ' EF8D349F'35 expect(resource[:id]).to eq '4BD6EC30' 36 36 end 37 37 end … … 39 39 context 'with a 64bit key id' do 40 40 let(:resource) { Puppet::Type.type(:apt_key).new( 41 :id => 'FFFFFFFF EF8D349F'41 :id => 'FFFFFFFF4BD6EC30' 42 42 )} 43 43 it 'id is set' do 44 expect(resource[:id]).to eq 'FFFFFFFF EF8D349F'44 expect(resource[:id]).to eq 'FFFFFFFF4BD6EC30' 45 45 end 46 46 end … … 48 48 context 'with a 0x formatted key id' do 49 49 let(:resource) { Puppet::Type.type(:apt_key).new( 50 :id => '0x EF8D349F'50 :id => '0x4BD6EC30' 51 51 )} 52 52 it 'id is set' do 53 expect(resource[:id]).to eq ' EF8D349F'53 expect(resource[:id]).to eq '4BD6EC30' 54 54 end 55 55 end … … 57 57 context 'with a 0x formatted lowercase key id' do 58 58 let(:resource) { Puppet::Type.type(:apt_key).new( 59 :id => '0x ef8d349f'59 :id => '0x4bd6ec30' 60 60 )} 61 61 it 'id is set' do 62 expect(resource[:id]).to eq ' EF8D349F'62 expect(resource[:id]).to eq '4BD6EC30' 63 63 end 64 64 end … … 66 66 context 'with a 0x formatted 64bit key id' do 67 67 let(:resource) { Puppet::Type.type(:apt_key).new( 68 :id => '0xFFFFFFFF EF8D349F'68 :id => '0xFFFFFFFF4BD6EC30' 69 69 )} 70 70 it 'id is set' do 71 expect(resource[:id]).to eq 'FFFFFFFF EF8D349F'71 expect(resource[:id]).to eq 'FFFFFFFF4BD6EC30' 72 72 end 73 73 end … … 75 75 context 'with source' do 76 76 let(:resource) { Puppet::Type.type(:apt_key).new( 77 :id => ' EF8D349F',77 :id => '4BD6EC30', 78 78 :source => 'http://apt.puppetlabs.com/pubkey.gpg' 79 79 )} … … 86 86 context 'with content' do 87 87 let(:resource) { Puppet::Type.type(:apt_key).new( 88 :id => ' EF8D349F',88 :id => '4BD6EC30', 89 89 :content => 'http://apt.puppetlabs.com/pubkey.gpg' 90 90 )} … … 97 97 context 'with keyserver' do 98 98 let(:resource) { Puppet::Type.type(:apt_key).new( 99 :id => ' EF8D349F',99 :id => '4BD6EC30', 100 100 :server => 'http://keyring.debian.org' 101 101 )} … … 109 109 it 'raises an error if content and source are set' do 110 110 expect { Puppet::Type.type(:apt_key).new( 111 :id => ' EF8D349F',111 :id => '4BD6EC30', 112 112 :source => 'http://apt.puppetlabs.com/pubkey.gpg', 113 113 :content => 'Completely invalid as a GPG key' … … 117 117 it 'raises an error if a weird length key is used' do 118 118 expect { Puppet::Type.type(:apt_key).new( 119 :id => 'F EF8D349F',119 :id => 'F4BD6EC30', 120 120 :source => 'http://apt.puppetlabs.com/pubkey.gpg', 121 121 :content => 'Completely invalid as a GPG key' … … 125 125 it 'raises an error when an invalid URI scheme is used in source' do 126 126 expect { Puppet::Type.type(:apt_key).new( 127 :id => ' EF8D349F',127 :id => '4BD6EC30', 128 128 :source => 'hkp://pgp.mit.edu' 129 129 )}.to raise_error(/Valid values match/) … … 132 132 it 'allows the http URI scheme in source' do 133 133 expect { Puppet::Type.type(:apt_key).new( 134 :id => ' EF8D349F',134 :id => '4BD6EC30', 135 135 :source => 'http://pgp.mit.edu' 136 )}.to_not raise_error137 end138 139 it 'allows the http URI with username and password' do140 expect { Puppet::Type.type(:apt_key).new(141 :id => '4BD6EC30',142 :source => 'http://testme:Password2@pgp.mit.edu'143 136 )}.to_not raise_error 144 137 end … … 146 139 it 'allows the https URI scheme in source' do 147 140 expect { Puppet::Type.type(:apt_key).new( 148 :id => ' EF8D349F',141 :id => '4BD6EC30', 149 142 :source => 'https://pgp.mit.edu' 150 143 )}.to_not raise_error … … 153 146 it 'allows the https URI with username and password' do 154 147 expect { Puppet::Type.type(:apt_key).new( 155 :id => ' EF8D349F',148 :id => '4BD6EC30', 156 149 :source => 'https://testme:Password2@pgp.mit.edu' 157 150 )}.to_not raise_error … … 160 153 it 'allows the ftp URI scheme in source' do 161 154 expect { Puppet::Type.type(:apt_key).new( 162 :id => ' EF8D349F',155 :id => '4BD6EC30', 163 156 :source => 'ftp://pgp.mit.edu' 164 157 )}.to_not raise_error … … 167 160 it 'allows an absolute path in source' do 168 161 expect { Puppet::Type.type(:apt_key).new( 169 :id => ' EF8D349F',162 :id => '4BD6EC30', 170 163 :source => '/path/to/a/file' 171 164 )}.to_not raise_error … … 174 167 it 'allows 5-digit ports' do 175 168 expect { Puppet::Type.type(:apt_key).new( 176 :id => ' EF8D349F',169 :id => '4BD6EC30', 177 170 :source => 'http://pgp.mit.edu:12345/key' 178 171 )}.to_not raise_error … … 181 174 it 'allows 5-digit ports when using key servers' do 182 175 expect { Puppet::Type.type(:apt_key).new( 183 :id => ' EF8D349F',176 :id => '4BD6EC30', 184 177 :server => 'http://pgp.mit.edu:12345' 185 178 )}.to_not raise_error -
src/puppetcode/environments/gnuboat/modules/gnuboat_gpsd/manifests/service.pp
rad28f83 rbcf0be5 6 6 String $devices = '/dev/ttyAMA0', 7 7 Boolean $network_access = false, 8 Boolean $poll_on_startup = false,9 8 ) 10 9 inherits gnuboat_gpsd … … 16 15 } 17 16 18 19 17 if(!$network_access) 20 18 { 21 $options _network= ''19 $options = '' 22 20 } 23 21 else 24 22 { 25 $options _network= '-G'23 $options = '-G' 26 24 $listen_stream = '0.0.0.0:2947' 27 25 file{'/etc/systemd/system/gpsd.socket': … … 44 42 } 45 43 46 if($poll_on_startup)47 {48 $options_startup = '-n'49 }50 else51 {52 $options_startup = ''53 }54 44 55 $options = [$options_network, $options_startup]56 45 file{'/etc/default/gpsd': 57 46 ensure => present, -
src/puppetcode/environments/gnuboat/modules/gnuboat_gpsd/templates/gpsd.epp
rad28f83 rbcf0be5 2 2 Boolean $usb_auto, 3 3 String $devices, 4 Array$options4 String $options 5 5 | -%> 6 6 # Default settings for the gpsd init script and the hotplug wrapper. … … 27 27 28 28 # Other options you want to pass to gpsd 29 GPSD_OPTIONS="<%= $options .join(' ')%>"29 GPSD_OPTIONS="<%= $options %>" -
src/puppetcode/environments/gnuboat/modules/stdlib/CHANGELOG.md
rad28f83 rbcf0be5 1 ## Supported Release 4.17.12 ### Summary3 4 Small release to address a bug (PUP-7650). Also pushes the Puppet version compatibility to 4.7.0.5 6 #### Bugfixes7 - (MODULES-5095) Workaround for PUP-76508 - (FM-6197) Formatting fixes for file_line resource9 10 11 ## Supported Release 4.17.012 ### Summary13 This release adds support for internationalization. It also contains Japanese translations for the README, summary and description of the metadata.json and major cleanups in the README. Additional folders have been introduced called locales and readmes where translation files can be found. A number of features and bug fixes are also included in this release. It also adds a new function `glob()` for expanding file lists. Also works around an issue that appeared in puppet 4.6.0 involving types being declared multiple times.14 15 #### Features16 - Addition of POT file / folder structure for i18n.17 - Addition of Internationalized READMEs.18 - `glob()` function19 20 ### Fixed21 - Occasional duplicate type definitions when using `defined_with_params()`22 - `file_line` encoding issue on ruby 1.8 (unsupported)23 - Huge readme refresh24 25 ## Supported Release 4.16.026 ### Summary27 28 This release sees a massive update to all unit tests to test UTF8 characters. There are also multiple cleanups in preparation for internationalization. Alongside this, improvements to ipv6 support, a new length function compatible with Puppet 4, and an update to path types. Also contains multiple bug fixes around functionality and tests.29 30 #### Features31 - Addition of coverage in all unit tests for functions, data and resource types for UTF8 for i18n.32 - All strings within the readme and functions that are split over two lines have been combined in preparation for i18n parser/decorator.33 - Improvement on the ipv6 support for type - Improves regex to catch some valid (but lesser known) ipv6 strings, mostly those which are a mix of ipv6 strings and embedded ipv6 numbers.34 - Adds a new parameter `encoding` to allow non UTF-8 files to specify a file encoding. This prevents receiving the error message "invalid byte sequence in UTF-8" when special characters that are not UTF-8 encoded appear in the input stream, such as the copyright symbol.35 - Addition of the new length function. Returns the length of a given string, array or hash. To eventually replace the deprecated size() function as can handle the new type functionality introduced in Puppet 4.36 - Permit double slash in absolute/Unix path types.37 38 #### Bugfixes39 - Fix unsupported data type error with rspec-puppet master.40 - Now allows test module metadata.json to be read by Puppet.41 - Fix acceptance test failure "Hiera is not a class".42 - Removal of unsupported platforms and future parser setting in acceptance tests.43 - Regex for tuple checking has been loosened.44 - Ensure_packages function - Now only tries to apply the resource if not defined.45 - (MODULES-4528) Use versioncmp to check Puppet version for 4.10.x compat.46 - Adds comments to warn for UTF8 incompatibility of the functions that may not be compatible with UTF8 with Ruby < 2.4.0.47 48 ## Supported Release 4.15.049 ### Summary50 51 This release introduces multiple new functions, a new fact and the addition of Ubuntu Xenial support. Also includes a bugfix and documentation update.52 53 #### Features54 - Addition of puppet_server fact to return agents server.55 - Addition of a pry function.56 - Addition of tests for ensure_resources.57 - Addition of FQDN UUID generation function.58 - Addition of Ubuntu Xenial to OS Support.59 60 ####Bugfixes61 - Ensure_packages now works with Ruby < 2.0.62 - Updated the documentation of str2bool function.63 64 ## Supported Release 4.14.065 ### Summary66 67 Adds several new features and updates, especially around refining the deprecation and validate_legacy functions. Also includes a Gemfile update around an issue with parallel_tests dependancy for different versions of Ruby.68 69 #### Features70 - Deprecation function now uses puppet stacktrace if available.71 - join_key_to_values function now handles array values. If values are arrays, multiple keys are added for each element.72 - Updated Gemfile to deal with parallel_tests Ruby dependancy (MODULES-3983).73 - Updated/Fixed ipv4 regex validator (MODULES-3980).74 - Deprecation clarification added to README.75 76 #### Bugfixes77 - README typo fixes.78 - Use .dup to duplicate classes for modification (MODULES-3829).79 - Fixes spec failures that were caused by a change in the tested error message in validate_legacy_spec.80 - Broken link to validate_legacy docs fixed.81 - Updates deprecation tests to include future parser.82 83 ## Supported Release 4.13.184 ### Summary85 86 This bugfix release addresses the `undefined method 'optional_repeated_param'` error messages seen by users of puppet 3.7.87 88 It also improves the user experience around function deprecations by emitting one warning per function(-name) instead of only one deprecation overall. This allows users to identify all deprecated functions used in one agent run, with less back-and-forth.89 90 #### Bugfixes91 92 * Emit deprecations warnings for each function, instead of once per process. (MODULES-3961)93 * Use a universally available API for the v4 deprecation stubs of `is_*` and `validate_*`. (MODULES-3962)94 * Make `getvar()` compatible to ruby 1.8.7. (MODULES-3969)95 * Add v4 deprecation stubs for the `is_` counterparts of the deprecated functions to emit the deprecations warnings in all cases.96 97 98 ## Supported Release 4.13.099 ### Summary100 101 This version of stdlib deprecates a whole host of functions, and provides stepping stones to move to Puppet 4 type validations. Be sure to check out the new `deprecation()` and `validate_legacy()` functions to migrate off the deprecated v3-style data validations.102 103 Many thanks to all community contributors: bob, Dmitry Ilyin, Dominic Cleal, Joris, Joseph Yaworski, Loic Antoine-Gombeaud, Maksym Melnychok, Michiel Brandenburg, Nate Potter, Romain Tartière, Stephen Benjamin, and Steve Moore, as well as anyone contributing in the code review process and by submitting issues.104 105 Special thanks to [Voxpupuli's](https://voxpupuli.org/) Igor Galić for donating the puppet-tea types to kickstart this part of stdlib.106 107 108 #### Deprecations109 * `validate_absolute_path`, `validate_array`, `validate_bool`, `validate_hash`, `validate_integer`, `validate_ip_address`, `validate_ipv4_address`, `validate_ipv6_address`, `validate_numeric`, `validate_re`, `validate_slength`, `validate_string`, and their `is_` counter parts are now deprecated on Puppet 4. See the `validate_legacy()` description in the README for help on migrating away from those functions.110 * The `dig` function is provided by core puppet since 4.5.0 with slightly different calling convention. The stdlib version can still be accessed as `dig44` for now.111 112 113 #### Features114 * Add Puppet 4 data types for Unix, and Windows paths, and URLs.115 * Add `deprecation` function to warn users of functionality that will be removed soon.116 * Add `validate_legacy` function to help with migrating to Puppet 4 data types.117 118 * Add `any2bool` function, a combination of of `string2bool` and `num2bool`.119 * Add `delete_regex` function to delete array elements matching a regular expression.120 * Add `puppet_environmentpath` fact to expose the `environmentpath` setting.121 * Add `regexpescape` function to safely insert arbitrary strings into regular expressions.122 * Add `shell_escape`, `shell_join`, and `shell_split` functions for safer working with shell scripts..123 124 * The `delete` function now also accepts regular expressions as search term.125 * The `loadyaml` function now accepts a default value, which is returned when there is an error loading the file.126 127 #### Bugfixes128 * Fix `file_line.match_for_absence` implementation and description to actually work. (MODULES-3590)129 * Fix `getparam` so that it can now also return `false`. (MODULES-3933)130 * Fix the fixture setup for testing and adjust `load_module_metadata` and `loadjson` tests.131 * Fix `defined_with_params` to handle `undef` correctly on all puppet versions. (PUP-6422, MODULES-3543)132 * Fix `file_line.path` validation to use puppet's built in `absolute_path?` matcher.133 134 #### Minor Improvements135 * README changes: improved descriptions of `deep_merge`, `delete`, `ensure_packages`, `file_line.after`, `range`, and `validate_numeric`.136 * The `getvar` function now returns nil in all situations where the variable is not found.137 * Update the `dig44` function with better `undef`, `nil`, and `false` handling.138 * Better wording on `str2bool` argument validation error message.139 140 141 ### Known issues142 * The `validate_legacy` function relies on internal APIs from Puppet 4.4.0 (PE 2016.1) onwards, and doesn't work on earlier versions.143 * Puppet 4.5.0 (PE 2016.2) has a number of improvements around data types - especially error handling - that make working with them much nicer.144 145 1 ## Supported Release 4.12.0 146 2 ###Summary -
src/puppetcode/environments/gnuboat/modules/stdlib/CONTRIBUTING.md
rad28f83 rbcf0be5 44 44 - Make sure you have a [GitHub account](https://github.com/join) 45 45 46 - [Create a ticket](https://tickets.puppet .com/secure/CreateIssue!default.jspa), or [watch the ticket](https://tickets.puppet.com/browse/) you are patching for.46 - [Create a ticket](https://tickets.puppetlabs.com/secure/CreateIssue!default.jspa), or [watch the ticket](https://tickets.puppetlabs.com/browse/) you are patching for. 47 47 48 48 * Preferred method: … … 209 209 ==================== 210 210 211 * [Getting additional help](http://puppet.com/community/get-help) 212 213 * [Writing tests](https://docs.puppet.com/guides/module_guides/bgtm.html#step-three-module-testing) 211 * [Getting additional help](http://puppetlabs.com/community/get-help) 212 213 * [Writing tests](http://projects.puppetlabs.com/projects/puppet/wiki/Development_Writing_Tests) 214 215 * [Patchwork](https://patchwork.puppetlabs.com) 214 216 215 217 * [General GitHub documentation](http://help.github.com/) 216 218 217 219 * [GitHub pull request documentation](http://help.github.com/send-pull-requests/) 220 -
src/puppetcode/environments/gnuboat/modules/stdlib/Gemfile
rad28f83 rbcf0be5 3 3 source ENV['GEM_SOURCE'] || "https://rubygems.org" 4 4 5 # Determines what type of gem is requested based on place_or_version. 6 def gem_type(place_or_version) 7 if place_or_version =~ /^git:/ 8 :git 9 elsif place_or_version =~ /^file:/ 10 :file 5 def location_for(place, version = nil) 6 if place =~ /^(git[:@][^#]*)#(.*)/ 7 [version, { :git => $1, :branch => $2, :require => false}].compact 8 elsif place =~ /^file:\/\/(.*)/ 9 ['>= 0', { :path => File.expand_path($1), :require => false}] 11 10 else 12 :gem11 [place, version, { :require => false}].compact 13 12 end 14 13 end 15 14 16 # Find a location or specific version for a gem. place_or_version can be a 17 # version, which is most often used. It can also be git, which is specified as 18 # `git://somewhere.git#branch`. You can also use a file source location, which 19 # is specified as `file://some/location/on/disk`. 20 def location_for(place_or_version, fake_version = nil) 21 if place_or_version =~ /^(git[:@][^#]*)#(.*)/ 22 [fake_version, { :git => $1, :branch => $2, :require => false }].compact 23 elsif place_or_version =~ /^file:\/\/(.*)/ 24 ['>= 0', { :path => File.expand_path($1), :require => false }] 25 else 26 [place_or_version, { :require => false }] 27 end 15 group :development, :unit_tests do 16 gem 'json', :require => false 17 gem 'metadata-json-lint', :require => false 18 gem 'puppet_facts', :require => false 19 gem 'puppet-blacksmith', :require => false 20 gem 'puppetlabs_spec_helper', :require => false 21 gem 'rspec-puppet', '>= 2.3.2', :require => false 22 gem 'simplecov', :require => false 23 end 24 group :system_tests do 25 gem 'beaker-rspec', *location_for(ENV['BEAKER_RSPEC_VERSION'] || '>= 3.4') 26 gem 'beaker', *location_for(ENV['BEAKER_VERSION']) 27 gem 'serverspec', :require => false 28 gem 'beaker-puppet_install_helper', :require => false 29 gem 'master_manipulator', :require => false 30 gem 'beaker-hostgenerator', *location_for(ENV['BEAKER_HOSTGENERATOR_VERSION']) 28 31 end 29 32 30 # Used for gem conditionals 31 supports_windows = false 32 ruby_version_segments = Gem::Version.new(RUBY_VERSION.dup).segments 33 minor_version = "#{ruby_version_segments[0]}.#{ruby_version_segments[1]}" 34 35 group :development do 36 gem "puppet-module-posix-default-r#{minor_version}", :require => false, :platforms => "ruby" 37 gem "puppet-module-win-default-r#{minor_version}", :require => false, :platforms => ["mswin", "mingw", "x64_mingw"] 38 gem "puppet-module-posix-dev-r#{minor_version}", :require => false, :platforms => "ruby" 39 gem "puppet-module-win-dev-r#{minor_version}", :require => false, :platforms => ["mswin", "mingw", "x64_mingw"] 40 gem "json_pure", '<= 2.0.1', :require => false if Gem::Version.new(RUBY_VERSION.dup) < Gem::Version.new('2.0.0') 41 gem "fast_gettext", '1.1.0', :require => false if Gem::Version.new(RUBY_VERSION.dup) < Gem::Version.new('2.1.0') 42 gem "fast_gettext", :require => false if Gem::Version.new(RUBY_VERSION.dup) >= Gem::Version.new('2.1.0') 43 end 44 45 group :system_tests do 46 gem "puppet-module-posix-system-r#{minor_version}", :require => false, :platforms => "ruby" 47 gem "puppet-module-win-system-r#{minor_version}", :require => false, :platforms => ["mswin", "mingw", "x64_mingw"] 48 gem "beaker", *location_for(ENV['BEAKER_VERSION'] || '>= 3') 49 gem "beaker-pe", :require => false 50 gem "beaker-rspec", *location_for(ENV['BEAKER_RSPEC_VERSION']) 51 gem "beaker-hostgenerator", *location_for(ENV['BEAKER_HOSTGENERATOR_VERSION']) 52 gem "beaker-abs", *location_for(ENV['BEAKER_ABS_VERSION'] || '~> 0.1') 53 end 54 33 gem 'facter', *location_for(ENV['FACTER_GEM_VERSION']) 55 34 gem 'puppet', *location_for(ENV['PUPPET_GEM_VERSION']) 56 35 57 # Only explicitly specify Facter/Hiera if a version has been specified.58 # Otherwise it can lead to strange bundler behavior. If you are seeing weird59 # gem resolution behavior, try setting `DEBUG_RESOLVER` environment variable60 # to `1` and then run bundle install.61 gem 'facter', *location_for(ENV['FACTER_GEM_VERSION']) if ENV['FACTER_GEM_VERSION']62 gem 'hiera', *location_for(ENV['HIERA_GEM_VERSION']) if ENV['HIERA_GEM_VERSION']63 36 64 65 # Evaluate Gemfile.local if it exists66 37 if File.exists? "#{__FILE__}.local" 67 38 eval(File.read("#{__FILE__}.local"), binding) 68 39 end 69 70 # Evaluate ~/.gemfile if it exists71 if File.exists?(File.join(Dir.home, '.gemfile'))72 eval(File.read(File.join(Dir.home, '.gemfile')), binding)73 end74 75 # vim:ft=ruby -
src/puppetcode/environments/gnuboat/modules/stdlib/Rakefile
rad28f83 rbcf0be5 1 require 'puppet_blacksmith/rake_tasks' 2 require 'puppet-lint/tasks/puppet-lint' 1 3 require 'puppetlabs_spec_helper/rake_tasks' 2 require 'puppet-lint/tasks/puppet-lint'3 require 'puppet_blacksmith/rake_tasks' if Bundler.rubygems.find_name('puppet-blacksmith').any?4 4 5 5 PuppetLint.configuration.fail_on_warnings = true 6 6 PuppetLint.configuration.send('relative') 7 PuppetLint.configuration.send('disable_80chars') 8 PuppetLint.configuration.send('disable_class_inherits_from_params_class') 9 PuppetLint.configuration.send('disable_documentation') 10 PuppetLint.configuration.send('disable_single_quote_string_with_variables') 11 PuppetLint.configuration.ignore_paths = ["spec/**/*.pp", "pkg/**/*.pp"] 7 12 8 13 desc 'Generate pooler nodesets' -
src/puppetcode/environments/gnuboat/modules/stdlib/checksums.json
rad28f83 rbcf0be5 1 1 { 2 "CHANGELOG.md": " b6fa51fd30594614b963fb98a6a0fffb",3 "CONTRIBUTING.md": " 77d0440d7cd4206497f99065c60bed46",4 "Gemfile": " bedf635025b279d7c7732adcc8ae9a29",2 "CHANGELOG.md": "62822f2fe9d7362a4b99156d01c846c4", 3 "CONTRIBUTING.md": "ad65d271f183b5adb9fdd58207939f5f", 4 "Gemfile": "a5493d10f1c1fec87972b13a9fe1afcf", 5 5 "LICENSE": "3b83ef96387f14655fc854ddc3c6bd57", 6 "MAINTAINERS.md": "b40ec4f2c16145af6f723c2c34bb2ff9",7 6 "NOTICE": "b2e552587e5969886fdd60481e8b0351", 8 "README.m d": "ac4c03f7f00304de7ed5a9eb9c6b84b7",7 "README.markdown": "9ff8d7869c0139409311df63f3bb0361", 9 8 "README_DEVELOPER.markdown": "220a8b28521b5c5d2ea87c4ddb511165", 10 9 "README_SPECS.markdown": "82bb4c6abbb711f40778b162ec0070c1", 11 10 "RELEASE_PROCESS.markdown": "94b92bc99ac4106ba1a74d5c04e520f9", 12 "Rakefile": "3851f083966b9bbd6d46e50dba5aa52a", 13 "appveyor.yml": "7e0ff52cc2abe3fa4f2d8d978bf18ad7", 14 "examples/file_line.pp": "d8126b139dd1dce21ff26910d1c5a245", 11 "Rakefile": "ab91824042ec3fd085a41cab7e0e90d4", 12 "examples/file_line.pp": "48f7f162127beffea8f8e3e58db2355a", 15 13 "examples/has_interface_with.pp": "d69d520cf3ff4d0b495480afaca359ef", 16 14 "examples/has_ip_address.pp": "32f42575e49aa66f0f2398a70ae2a9f4", … … 20 18 "lib/facter/package_provider.rb": "539766a71dfb2f65e94a7c91bf413fcf", 21 19 "lib/facter/pe_version.rb": "60d47406026c8201e51394227ddf780d", 22 "lib/facter/puppet_ settings.rb": "9438c0839ae28dc52fffb8348ae5124f",20 "lib/facter/puppet_vardir.rb": "c7ddc97e8a84ded3dd93baa5b9b3283d", 23 21 "lib/facter/root_home.rb": "35702ae0c7410ec4d2101113e2f697fa", 24 22 "lib/facter/service_provider.rb": "66cc42526eae631e306b397391f1f01c", 25 23 "lib/facter/util/puppet_settings.rb": "9f1d2593d0ae56bfca89d4b9266aeee1", 26 "lib/puppet/functions/deprecation.rb": "59b803eaa15b5a559040497bffc172ae",27 24 "lib/puppet/functions/is_a.rb": "9dad7f8c9b75348cd97aca986ac0b29a", 28 "lib/puppet/functions/is_absolute_path.rb": "96b217f26d06dbac87a2c6a8cfd2d8c8", 29 "lib/puppet/functions/is_array.rb": "9292a646010d167417a1936b0b0c17b9", 30 "lib/puppet/functions/is_bool.rb": "73957f9efd75ed8a7ab867f9de6da117", 31 "lib/puppet/functions/is_float.rb": "af3bd6bb56878bac8cc4fe4f7564e4f9", 32 "lib/puppet/functions/is_ip_address.rb": "ee231c66c3e039778bf46702d89815a6", 33 "lib/puppet/functions/is_ipv4_address.rb": "900d33249906c4daa02aa79cac896548", 34 "lib/puppet/functions/is_ipv6_address.rb": "568fba9af6a83c8b536fafcda82eb448", 35 "lib/puppet/functions/is_numeric.rb": "33051800b886cc3b2119826b77c9821a", 36 "lib/puppet/functions/is_string.rb": "230e9eabc5c9e1d8d5fb7b3c6c12b300", 37 "lib/puppet/functions/length.rb": "03cf801867a919f801d290424fd2bb8d", 38 "lib/puppet/functions/type_of.rb": "bec00841aae556993c926ab298bc81cd", 39 "lib/puppet/functions/validate_absolute_path.rb": "54a610baa115c7505f1b35976b632a8e", 40 "lib/puppet/functions/validate_array.rb": "9052b0026da174636c276a2512cf5acc", 41 "lib/puppet/functions/validate_bool.rb": "fe979e402a5a3a19d013ce84b39ef06a", 42 "lib/puppet/functions/validate_hash.rb": "92ea8fc21bbbf6cc41f6bb9cfcaefce7", 43 "lib/puppet/functions/validate_integer.rb": "b0982b68a599262da2c6f2e032bc7713", 44 "lib/puppet/functions/validate_ip_address.rb": "65a12af9a2c2a9c70d820d04d19ec891", 45 "lib/puppet/functions/validate_ipv4_address.rb": "4a5039b99ac97cc0447faa343b9f7416", 46 "lib/puppet/functions/validate_ipv6_address.rb": "fbdf685432416505fed27d5647c26f9c", 47 "lib/puppet/functions/validate_legacy.rb": "d9f115f30c511cef536a821b94826094", 48 "lib/puppet/functions/validate_numeric.rb": "41b2cc7335395f617c2bfbeac8f579da", 49 "lib/puppet/functions/validate_re.rb": "42092f592ebf89b8a504b10c900230d8", 50 "lib/puppet/functions/validate_slength.rb": "3ae6fcc3f60032c923d06ab3e457b84e", 51 "lib/puppet/functions/validate_string.rb": "cc967a9d0ea156b2208d1760d7f6e1b2", 52 "lib/puppet/parser/functions/abs.rb": "a8e46ecf4fb378d314916599651cebe5", 25 "lib/puppet/functions/type_of.rb": "71e19f89e167c45ec691ea6c7d319625", 26 "lib/puppet/parser/functions/abs.rb": "32161bd0435fdfc2aec2fc559d2b454b", 53 27 "lib/puppet/parser/functions/any2array.rb": "a81e71d6b67a551d38770ba9a1948a75", 54 "lib/puppet/parser/functions/any2bool.rb": "8bbb74cb81ebdb164e1965415364080b", 55 "lib/puppet/parser/functions/assert_private.rb": "cb9cd79ed4e3d647a48467dfb6237d5c", 56 "lib/puppet/parser/functions/base64.rb": "0d121a32fbfe25b06a4e91b0259af91d", 28 "lib/puppet/parser/functions/assert_private.rb": "1365284f9e474ecec24cfe43ee8e7cf4", 29 "lib/puppet/parser/functions/base64.rb": "ac8d0565df2931470447effa502c9ad3", 57 30 "lib/puppet/parser/functions/basename.rb": "c61952b3f68fd86408c84fca2c3febb1", 58 "lib/puppet/parser/functions/bool2num.rb": " 01b070b02611fda7e1491de0a8cd89fc",59 "lib/puppet/parser/functions/bool2str.rb": " c00885242abf381ba482644ded70b688",60 "lib/puppet/parser/functions/camelcase.rb": " bd5da699dfe1ec27ffe91b06187c5900",61 "lib/puppet/parser/functions/capitalize.rb": " c94c50b0f147a22861c3b93c724e4343",62 "lib/puppet/parser/functions/ceiling.rb": " 7de4a96c8bb645fd5ce5c38438667228",63 "lib/puppet/parser/functions/chomp.rb": " 35a16c85bc59dc285baae631da1ae771",64 "lib/puppet/parser/functions/chop.rb": " 3beb80906fa3c759945a2664fe510b20",65 "lib/puppet/parser/functions/clamp.rb": " 6920e6c11b575fc65dadb21220c01a7a",66 "lib/puppet/parser/functions/concat.rb": " d10e5428917895d4bb90c638b148b7fa",31 "lib/puppet/parser/functions/bool2num.rb": "f953f5fc094c2ae3908a72d8840ba291", 32 "lib/puppet/parser/functions/bool2str.rb": "6334ac6d24a8aa49a2243fb425f47311", 33 "lib/puppet/parser/functions/camelcase.rb": "71c67b71eac4b7f46a0dd22cb915d2e6", 34 "lib/puppet/parser/functions/capitalize.rb": "da131748a9d32da9eb0b6438e39377eb", 35 "lib/puppet/parser/functions/ceiling.rb": "dfa9b1c75ce89344026b3b5aed2d190f", 36 "lib/puppet/parser/functions/chomp.rb": "2b7dc42f9967edd34cfa0ba9a97229ca", 37 "lib/puppet/parser/functions/chop.rb": "0ec76f54afd94201f35785dfeb2092b5", 38 "lib/puppet/parser/functions/clamp.rb": "d19b8dfc573ed2eff7e3536ae1e5d596", 39 "lib/puppet/parser/functions/concat.rb": "a1b0233e58f1f8095a74fe9300c74a9b", 67 40 "lib/puppet/parser/functions/convert_base.rb": "c3b3e59a49318af98dcb88aed7156629", 68 "lib/puppet/parser/functions/count.rb": " 325bbd89a29e6ed0f31e0462d0a0d301",41 "lib/puppet/parser/functions/count.rb": "9eb74eccd93e2b3c87fd5ea14e329eba", 69 42 "lib/puppet/parser/functions/deep_merge.rb": "d83696855578fb81b64b9e92b9c7cc7c", 70 "lib/puppet/parser/functions/defined_with_params.rb": "2d964410afbee415446c94d9692a2112", 71 "lib/puppet/parser/functions/delete.rb": "7af1540fee4285d93b6b28fb490db70a", 72 "lib/puppet/parser/functions/delete_at.rb": "a2cba60ac86a676d4ed1ff846a917014", 73 "lib/puppet/parser/functions/delete_regex.rb": "91cd012ef5a636ffe541814ed232b909", 74 "lib/puppet/parser/functions/delete_undef_values.rb": "52beef9ee37f84ed2278a69ec4383125", 75 "lib/puppet/parser/functions/delete_values.rb": "b410f5618b4a6158a921acb7b2dc628d", 76 "lib/puppet/parser/functions/deprecation.rb": "4323210434d36e37977251f906a232b8", 77 "lib/puppet/parser/functions/difference.rb": "467e44aeaebd0ee0a51c8b89e3769f1f", 78 "lib/puppet/parser/functions/dig.rb": "1a2a8918f646c13dcb9876a22f9295ab", 79 "lib/puppet/parser/functions/dig44.rb": "3078b97ee941c261944857373d400ed6", 43 "lib/puppet/parser/functions/defined_with_params.rb": "ffab4433d03f32b551f2ea024a2948fc", 44 "lib/puppet/parser/functions/delete.rb": "cec92c5de6d748c8dc93ca7d25ac1c68", 45 "lib/puppet/parser/functions/delete_at.rb": "6bc24b79390d463d8be95396c963381a", 46 "lib/puppet/parser/functions/delete_undef_values.rb": "b32d4a3925753b2eb2c318cbd7f14404", 47 "lib/puppet/parser/functions/delete_values.rb": "39b147f7d369bb5f809044b6341954a2", 48 "lib/puppet/parser/functions/difference.rb": "e31b95fbaf974cf853a510177368bfb9", 49 "lib/puppet/parser/functions/dig.rb": "54a993e69c2673d999876cb3349984b7", 80 50 "lib/puppet/parser/functions/dirname.rb": "8a5579f9a9a13fd737ba65eccf8e6d5a", 81 51 "lib/puppet/parser/functions/dos2unix.rb": "be8359a5106a7832be4180e8207dd586", 82 "lib/puppet/parser/functions/downcase.rb": " 02376505a00accd0ce6b148f869c9c86",83 "lib/puppet/parser/functions/empty.rb": " 6d7d2dde2971f6a40fa913f0af1c610c",84 "lib/puppet/parser/functions/enclose_ipv6.rb": " ec39936a9a51dc5cb8ada6eeb829b239",85 "lib/puppet/parser/functions/ensure_packages.rb": " 362fac217452d0eee783be7c7ab3a569",52 "lib/puppet/parser/functions/downcase.rb": "73121616d73339cf8dd10e0de61a6c50", 53 "lib/puppet/parser/functions/empty.rb": "b4ad0c3c00cbc56f745fbc05af1efa00", 54 "lib/puppet/parser/functions/enclose_ipv6.rb": "581bc163291824909d1700909db96512", 55 "lib/puppet/parser/functions/ensure_packages.rb": "81a8edbd7b6f85fc90e458568184c356", 86 56 "lib/puppet/parser/functions/ensure_resource.rb": "de703fe63392b939fc2b4392975263de", 87 "lib/puppet/parser/functions/ensure_resources.rb": " c92d8b69d6354eda24aa3a13d88177b2",88 "lib/puppet/parser/functions/flatten.rb": " 6a27f5b922a24fec6e823f6f51c98090",89 "lib/puppet/parser/functions/floor.rb": " 07ba3b1662a14c60fe908b51231355ee",57 "lib/puppet/parser/functions/ensure_resources.rb": "e9543e167972dd6a9a88aa5e02a9b4a5", 58 "lib/puppet/parser/functions/flatten.rb": "25777b76f9719162a8bab640e5595b7a", 59 "lib/puppet/parser/functions/floor.rb": "42cad4c689231a51526c55a6f0985d1f", 90 60 "lib/puppet/parser/functions/fqdn_rand_string.rb": "9ac5f18e563094aee62ef7586267025d", 91 "lib/puppet/parser/functions/fqdn_rotate.rb": "2483d17df4e6cb25d92b4e8520f30957", 92 "lib/puppet/parser/functions/fqdn_uuid.rb": "d357e8837ba2ed8196e926f3697be521", 61 "lib/puppet/parser/functions/fqdn_rotate.rb": "770d510a2e50d19b2dd42b6edef3fb1f", 93 62 "lib/puppet/parser/functions/get_module_path.rb": "d4bf50da25c0b98d26b75354fa1bcc45", 94 "lib/puppet/parser/functions/getparam.rb": "440a9c381b9ad589504e2e9919e83c06", 95 "lib/puppet/parser/functions/getvar.rb": "0c8c5cef7e158e232a8cf6e42c10d0ff", 96 "lib/puppet/parser/functions/glob.rb": "c4106d2aff24f4b5a32b54bf4cd452a2", 97 "lib/puppet/parser/functions/grep.rb": "c2f2dbdf79d16584579c3a7bc7b5902f", 98 "lib/puppet/parser/functions/has_interface_with.rb": "db65f5aac94e8fe105c7ca0cd1f66403", 99 "lib/puppet/parser/functions/has_ip_address.rb": "6ce9e6cdfb499b6ce86bf531848a18be", 100 "lib/puppet/parser/functions/has_ip_network.rb": "3cc7b923fd3cde5062ed9d0eaaa8155f", 63 "lib/puppet/parser/functions/getparam.rb": "4dd7a0e35f4a3780dcfc9b19b4e0006e", 64 "lib/puppet/parser/functions/getvar.rb": "344f1ce85dcb7512d37e8702ccbabb66", 65 "lib/puppet/parser/functions/grep.rb": "5682995af458b05f3b53dd794c4bf896", 66 "lib/puppet/parser/functions/has_interface_with.rb": "e135f09dbecc038c3aa9ae03127617ef", 67 "lib/puppet/parser/functions/has_ip_address.rb": "ee207f47906455a5aa49c4fb219dd325", 68 "lib/puppet/parser/functions/has_ip_network.rb": "b4d726c8b2a0afac81ced8a3a28aa731", 101 69 "lib/puppet/parser/functions/has_key.rb": "7cd9728c38f0b0065f832dabd62b0e7e", 102 "lib/puppet/parser/functions/hash.rb": " c1ebb21cc5b984153a87c252a9854db2",103 "lib/puppet/parser/functions/intersection.rb": " 87469eb81ab00bbacfd744165beeaeec",104 "lib/puppet/parser/functions/is_absolute_path.rb": " 1ce9a6d1cd0a79087d73cb879ed04542",105 "lib/puppet/parser/functions/is_array.rb": " bbce6768b688bc0f36978ecb0f60f7f4",106 "lib/puppet/parser/functions/is_bool.rb": " b8800ff7a11b4e8c03616041e218225f",107 "lib/puppet/parser/functions/is_domain_name.rb": " 5c6106c070945a605c5adbd1852f0691",108 "lib/puppet/parser/functions/is_email_address.rb": " 1eb786779743e93a7bb9fe8087b38b8d",109 "lib/puppet/parser/functions/is_float.rb": " 6257620b98c5099293be7aa4088b88ce",110 "lib/puppet/parser/functions/is_function_available.rb": " f13934d6b41561ef54d88cf0da86231b",111 "lib/puppet/parser/functions/is_hash.rb": " 6f1ccf659c41cb5dab4db9fa89f0b364",112 "lib/puppet/parser/functions/is_integer.rb": " a4ae475a5a799c0cc46519e86aed2973",113 "lib/puppet/parser/functions/is_ip_address.rb": " 2eabe60c213df2e642a03ebfd4852497",114 "lib/puppet/parser/functions/is_ipv4_address.rb": " ab854b47367921f657410fbe79054f0b",115 "lib/puppet/parser/functions/is_ipv6_address.rb": " 2a2be7adbdd5ca23c3e21f00d7d8bac7",116 "lib/puppet/parser/functions/is_mac_address.rb": " 1af27510d3b9b936384192a4e1dfbf8c",117 "lib/puppet/parser/functions/is_numeric.rb": " bfd99f39e2506953ad00178db6fa07ea",118 "lib/puppet/parser/functions/is_string.rb": " c1405dd293e9e3c738b83c4ef5aab1ef",119 "lib/puppet/parser/functions/join.rb": " 2ed4f56d296a4535da142e01b11a126d",120 "lib/puppet/parser/functions/join_keys_to_values.rb": " 71ad24ac1809739713c461141aedd082",121 "lib/puppet/parser/functions/keys.rb": " c10485a3d6c53b6d57a891b9852898de",70 "lib/puppet/parser/functions/hash.rb": "784f8d2d114eb4c9414ebd8a6868f82f", 71 "lib/puppet/parser/functions/intersection.rb": "c8f4f8b861c9c297c87b08bdbfb94caa", 72 "lib/puppet/parser/functions/is_absolute_path.rb": "94ea1869c438d23f7f659c87ced8080a", 73 "lib/puppet/parser/functions/is_array.rb": "875ca4356cb0d7a10606fb146b4a3d11", 74 "lib/puppet/parser/functions/is_bool.rb": "e693b7c4b5366cff1380b6e0c7dd7b11", 75 "lib/puppet/parser/functions/is_domain_name.rb": "6ca1f2708add756a6803b29d593d5830", 76 "lib/puppet/parser/functions/is_email_address.rb": "82573a431edf5a0bf9847393af27566a", 77 "lib/puppet/parser/functions/is_float.rb": "10e0d3ecf75fac15e415aee79acf70dc", 78 "lib/puppet/parser/functions/is_function_available.rb": "628428bbcd9313ce09783d9484330e09", 79 "lib/puppet/parser/functions/is_hash.rb": "8c7d9a05084dab0389d1b779c8a05b1a", 80 "lib/puppet/parser/functions/is_integer.rb": "c665be82686aa4729959bb42c66a7510", 81 "lib/puppet/parser/functions/is_ip_address.rb": "a714a736c1560e8739aaacd9030cca00", 82 "lib/puppet/parser/functions/is_ipv4_address.rb": "3df98fc55d9d59e0706ff83f607bb2a8", 83 "lib/puppet/parser/functions/is_ipv6_address.rb": "16e88af742f8ac93f1e8bb562eebc593", 84 "lib/puppet/parser/functions/is_mac_address.rb": "6dd3c96437d49e68630869b0b464e7f2", 85 "lib/puppet/parser/functions/is_numeric.rb": "93ddc9d4c0834a5e5e0562d7b3cdce91", 86 "lib/puppet/parser/functions/is_string.rb": "2bd9a652bbb2668323eee6c57729ff64", 87 "lib/puppet/parser/functions/join.rb": "a285a05c015ae278608f6454aef211ea", 88 "lib/puppet/parser/functions/join_keys_to_values.rb": "f29da49531228f6ca5b3aa0df00a14c2", 89 "lib/puppet/parser/functions/keys.rb": "eb6ac815ea14fbf423580ed903ef7bad", 122 90 "lib/puppet/parser/functions/load_module_metadata.rb": "805c5476a6e7083d133e167129885924", 123 "lib/puppet/parser/functions/loadjson.rb": "ffecf61ba2ec8011915d37009b1a273e", 124 "lib/puppet/parser/functions/loadyaml.rb": "668265f14327cba1d1400f2078b7b26b", 125 "lib/puppet/parser/functions/lstrip.rb": "e9cbd5c2233233940e7344478362fb9f", 126 "lib/puppet/parser/functions/max.rb": "529eb6ac3d88c03caa788167594bd487", 127 "lib/puppet/parser/functions/member.rb": "03d618926bbb9efd117950e6078c3878", 91 "lib/puppet/parser/functions/loadyaml.rb": "6da5dc9256c9e7a6549bb15c72cb9f9d", 92 "lib/puppet/parser/functions/lstrip.rb": "20a9b1fa077c16f34e0ef5448b895698", 93 "lib/puppet/parser/functions/max.rb": "f652fd0b46ef7d2fbdb42b141f8fdd1d", 94 "lib/puppet/parser/functions/member.rb": "2b5d7fb8f87f1c7d195933c57ca32e91", 128 95 "lib/puppet/parser/functions/merge.rb": "f3dcc5c83440cdda2036cce69b61a14b", 129 "lib/puppet/parser/functions/min.rb": " 8d829c8a55c9330ab02f962926221d4f",130 "lib/puppet/parser/functions/num2bool.rb": " ddb603cf74f92e16a00f1447a4403429",96 "lib/puppet/parser/functions/min.rb": "0d2a1b7e735ab251c5469e735fa3f4c6", 97 "lib/puppet/parser/functions/num2bool.rb": "605c12fa518c87ed2c66ae153e0686ce", 131 98 "lib/puppet/parser/functions/parsejson.rb": "15165fd3807d9f3d657697fa854d643d", 132 99 "lib/puppet/parser/functions/parseyaml.rb": "db54578d9d798ced75952217cf11b737", 133 100 "lib/puppet/parser/functions/pick.rb": "bf01f13bbfe2318e7f6a302ac7c4433f", 134 101 "lib/puppet/parser/functions/pick_default.rb": "ad3ea60262de408767786d37a54d45dc", 135 "lib/puppet/parser/functions/prefix.rb": "e ce9341c5b232a25c58545718a54e92f",102 "lib/puppet/parser/functions/prefix.rb": "e377fd64bd63dde6c9660aa75aca4942", 136 103 "lib/puppet/parser/functions/private.rb": "1500a21d5cf19961c5b1d476df892d92", 137 "lib/puppet/parser/functions/pry.rb": "79a48e45196e4bbf0a3e658781513cf4", 138 "lib/puppet/parser/functions/pw_hash.rb": "3d540eb4c483cc9c111794ac2d24a4a7", 139 "lib/puppet/parser/functions/range.rb": "ab19430b6b9737cf56263eb65d80cba1", 140 "lib/puppet/parser/functions/regexpescape.rb": "6378fdd413237a37c322859877147a50", 104 "lib/puppet/parser/functions/pw_hash.rb": "d82221f667050026cd6d155432a31802", 105 "lib/puppet/parser/functions/range.rb": "76f693d1dd50ffee409e58ff6d9a58bb", 141 106 "lib/puppet/parser/functions/reject.rb": "689f6a7c961a55fe9dcd240921f4c7f9", 142 "lib/puppet/parser/functions/reverse.rb": " 209e7ef512963251571c515e2d0aee10",143 "lib/puppet/parser/functions/rstrip.rb": " f3226709247741825f07d9ec20bd3887",107 "lib/puppet/parser/functions/reverse.rb": "b234b54b8cd62b2d67ccd70489ffdccf", 108 "lib/puppet/parser/functions/rstrip.rb": "b4e4ada41f7c1d2fcad073ce6344980f", 144 109 "lib/puppet/parser/functions/seeded_rand.rb": "2ad22e7613d894ae779c0c5b0e65dade", 145 "lib/puppet/parser/functions/shell_escape.rb": "13662933244e1af42ddca71ced4ac9e5", 146 "lib/puppet/parser/functions/shell_join.rb": "b99a23d5e62e2e1b98accde5c22e45c9", 147 "lib/puppet/parser/functions/shell_split.rb": "5317d71f3a7e293624b57aaca23f57d5", 148 "lib/puppet/parser/functions/shuffle.rb": "6c0555524ebc9ed5dd8295b836fb7163", 149 "lib/puppet/parser/functions/size.rb": "c171d46b87e377ebcc710ad5a5925a2b", 150 "lib/puppet/parser/functions/sort.rb": "0b7d1411decc4a92450828809fad0779", 151 "lib/puppet/parser/functions/squeeze.rb": "403ea46228a8e45e89c91168ed301fb6", 152 "lib/puppet/parser/functions/str2bool.rb": "ff82f179970a9429614bd37fa7a1ae2a", 153 "lib/puppet/parser/functions/str2saltedsha512.rb": "457ab12e4329494ae6276cfa4f20eb23", 154 "lib/puppet/parser/functions/strftime.rb": "8f15e2e3732b6d1d357a1fa1826800d4", 155 "lib/puppet/parser/functions/strip.rb": "da0ce253cb63a4863f15f9d145217db5", 156 "lib/puppet/parser/functions/suffix.rb": "1ce493098f17ea47e9435f994adbc6cd", 157 "lib/puppet/parser/functions/swapcase.rb": "48cad9bf415b5d79584c8e17ab7a06cc", 158 "lib/puppet/parser/functions/time.rb": "cd96d1f039f8875af083091e3637190b", 159 "lib/puppet/parser/functions/to_bytes.rb": "45248fd0bba8cfb24eac830fc0add17a", 110 "lib/puppet/parser/functions/shuffle.rb": "d50f72b0aeb921e64d2482f62488e2f3", 111 "lib/puppet/parser/functions/size.rb": "ab3b5b8cf2369d76969a7cb2564e018f", 112 "lib/puppet/parser/functions/sort.rb": "504b033b438461ca4f9764feeb017833", 113 "lib/puppet/parser/functions/squeeze.rb": "541f85b4203b55c9931d3d6ecd5c75f8", 114 "lib/puppet/parser/functions/str2bool.rb": "e380cfbc3395404ac8232ff960b22bca", 115 "lib/puppet/parser/functions/str2saltedsha512.rb": "49afad7b386be38ce53deaefef326e85", 116 "lib/puppet/parser/functions/strftime.rb": "e02e01a598ca5d7d6eee0ba22440304a", 117 "lib/puppet/parser/functions/strip.rb": "85d70ab95492e3e4ca5f0b5ec3f284a9", 118 "lib/puppet/parser/functions/suffix.rb": "082519722ed6f237dd3a9a7e316ab2e4", 119 "lib/puppet/parser/functions/swapcase.rb": "b17a9f3cb0271451d309e4b4f52dd651", 120 "lib/puppet/parser/functions/time.rb": "8cb0b8320c60b4a21725634154a9f1db", 121 "lib/puppet/parser/functions/to_bytes.rb": "65437027687b6172173b3a211a799e37", 160 122 "lib/puppet/parser/functions/try_get_value.rb": "09cd079ec5f0e5e2ac862c9ebe0f54fe", 161 123 "lib/puppet/parser/functions/type.rb": "4709f7ab8a8aad62d77a3c5d91a3aa08", 162 "lib/puppet/parser/functions/type3x.rb": " 5d0391205bd1cfe8de985a44e8c3e8a9",163 "lib/puppet/parser/functions/union.rb": " c02fca3fe102875ba020072b7edee532",164 "lib/puppet/parser/functions/unique.rb": " 0f79a96896149f7034cd85e31eed1e54",124 "lib/puppet/parser/functions/type3x.rb": "f9bf4de8341afb0c677c26b40ec8a2b2", 125 "lib/puppet/parser/functions/union.rb": "3cf57ea53f2522f586264feb67293cd6", 126 "lib/puppet/parser/functions/unique.rb": "c1bb4a8aeebd09ba3e4c8bc3702cfd60", 165 127 "lib/puppet/parser/functions/unix2dos.rb": "b1f5087fcaca69d9395094204cce887a", 166 "lib/puppet/parser/functions/upcase.rb": " e875fc4f03adec1ff3b42d22f177441e",167 "lib/puppet/parser/functions/uriescape.rb": " ba78def2cd0e60bdc4412df6c7b891ec",168 "lib/puppet/parser/functions/validate_absolute_path.rb": " c4b12e101055380386a235cd2c92ad10",169 "lib/puppet/parser/functions/validate_array.rb": " bee8327014714d4cd8dbb5c46611f594",128 "lib/puppet/parser/functions/upcase.rb": "8decededec9eb33e58f961eb86f0888f", 129 "lib/puppet/parser/functions/uriescape.rb": "d912ba09ba3f58c70988e662e05ffbe8", 130 "lib/puppet/parser/functions/validate_absolute_path.rb": "51c81d562fcc6c2df49ce5cfefd721ff", 131 "lib/puppet/parser/functions/validate_array.rb": "72b29289b8af1cfc3662ef9be78911b8", 170 132 "lib/puppet/parser/functions/validate_augeas.rb": "61e828e7759ba3e1e563e1fdd68aa80f", 171 "lib/puppet/parser/functions/validate_bool.rb": " 971700229c4b581f67f6fadc9019eb2c",133 "lib/puppet/parser/functions/validate_bool.rb": "a712634a000024398b3c6cd4ecc46463", 172 134 "lib/puppet/parser/functions/validate_cmd.rb": "7df12370db442eddddcf4dd7a5364b5e", 173 "lib/puppet/parser/functions/validate_email_address.rb": " a72656cbfeda622cdd5cfdafdf464095",174 "lib/puppet/parser/functions/validate_hash.rb": " c2ae6299148ea200f8dfcf9204875182",175 "lib/puppet/parser/functions/validate_integer.rb": " 65aa35f7450794aaadb6ad2c2e114df7",176 "lib/puppet/parser/functions/validate_ip_address.rb": " b23c3d5ce6839e32d0186411147a6a44",177 "lib/puppet/parser/functions/validate_ipv4_address.rb": " 593e8f832469cb6a48c5f16ee66c3b2d",178 "lib/puppet/parser/functions/validate_ipv6_address.rb": "4 8d3733012818993eae662839183d139",179 "lib/puppet/parser/functions/validate_numeric.rb": " 0e36d370262b8bdef2f88f0a3cb5b30e",180 "lib/puppet/parser/functions/validate_re.rb": " d5963c404e3ac1670553f306221c2655",181 "lib/puppet/parser/functions/validate_slength.rb": " 6cbcfe15378ca4a780bac786223aacac",182 "lib/puppet/parser/functions/validate_string.rb": " 8afa7b0dcfe17bfbbb5704ad54664cc2",135 "lib/puppet/parser/functions/validate_email_address.rb": "e74fe9695ae0219d95f1595978267e48", 136 "lib/puppet/parser/functions/validate_hash.rb": "e9cfaca68751524efe16ecf2f958a9a0", 137 "lib/puppet/parser/functions/validate_integer.rb": "438c7fdd25f7f6a208ac48c9b75a390f", 138 "lib/puppet/parser/functions/validate_ip_address.rb": "8d1f23b4fb623e9ce2a6bfa59c6c1266", 139 "lib/puppet/parser/functions/validate_ipv4_address.rb": "ea5a7e87f51fc5a961cdc7369b3c9d00", 140 "lib/puppet/parser/functions/validate_ipv6_address.rb": "4699238e4cad60e7e1428905523eaeb7", 141 "lib/puppet/parser/functions/validate_numeric.rb": "60b0c6d5b8b170ea77498a8580bd3158", 142 "lib/puppet/parser/functions/validate_re.rb": "53613813ba02914f2692f0edd7e12fab", 143 "lib/puppet/parser/functions/validate_slength.rb": "5f0db124caae4866f474a60c589ba632", 144 "lib/puppet/parser/functions/validate_string.rb": "cf6a20877a27b1073d63fdd522af50bb", 183 145 "lib/puppet/parser/functions/validate_x509_rsa_key_pair.rb": "f17427dfc42128dc1df0ab04f37942e5", 184 "lib/puppet/parser/functions/values.rb": " c35978761496406cc3dafdccaa014236",185 "lib/puppet/parser/functions/values_at.rb": " f7e6ad2a1126acd4fb5f7fcf9bfc2e2b",186 "lib/puppet/parser/functions/zip.rb": " 133f3d4c54640844e656e2e6e790318e",187 "lib/puppet/provider/file_line/ruby.rb": " 97dee0cadfaf112550e8424e143acc55",146 "lib/puppet/parser/functions/values.rb": "066a6e4170e5034edb9a80463dff2bb5", 147 "lib/puppet/parser/functions/values_at.rb": "325a899e0201e8df5bd483fec6f12d76", 148 "lib/puppet/parser/functions/zip.rb": "a89d5e802bc1e63e52020c2ddbaaca2c", 149 "lib/puppet/provider/file_line/ruby.rb": "0b7ed2917e70902b5c40362370edcbb0", 188 150 "lib/puppet/type/anchor.rb": "bbd36bb49c3b554f8602d8d3df366c0c", 189 "lib/puppet/type/file_line.rb": "d65885f7f0afe49ee199d6bf873a5daf", 190 "locales/config.yaml": "574ee65e2a2a9d2f67edbc58735f50d4", 191 "locales/ja/puppetlabs-stdlib.po": "805e5d893d2025ad57da8ec0614a6753", 192 "locales/puppetlabs-stdlib.pot": "23c892ac0683aef4b09aabe0037750ae", 151 "lib/puppet/type/file_line.rb": "21214f23b82b909dba6d7a57dd6464b6", 193 152 "manifests/init.pp": "9560a09f657d7eebbfdb920cefcc1d4f", 194 153 "manifests/stages.pp": "72eb4fa624474faf23b39e57cf1590bd", 195 "metadata.json": "72d1000d449f8b37a4da8167a51edc05", 196 "readmes/README_ja_JP.md": "173d377936c83b2cd622bb471d154a02", 197 "spec/acceptance/abs_spec.rb": "5b60756b2b4da28314025f51989592d7", 198 "spec/acceptance/anchor_spec.rb": "0fdbe266d8b7c3dc172e338b978109ba", 199 "spec/acceptance/any2array_spec.rb": "444cfd34154539d896e5ef1488386372", 200 "spec/acceptance/base64_spec.rb": "6a1dd4144ba354f9bed14eb70f7d2cba", 201 "spec/acceptance/bool2num_spec.rb": "edc9cb8b89b95410326475d27ce74bd5", 154 "metadata.json": "cab692227f5bbcc300d1512b4c8600dd", 155 "spec/acceptance/abs_spec.rb": "538db8d037db814b455a6d741e91bb8d", 156 "spec/acceptance/anchor_spec.rb": "3a366ecab2fda6c20acd70eeb57c5080", 157 "spec/acceptance/any2array_spec.rb": "de86ead0205acbb3eca3a8a4792bdac8", 158 "spec/acceptance/base64_spec.rb": "1684d5dd176dd5bbd4c3c6b1e64fbcea", 159 "spec/acceptance/bool2num_spec.rb": "bf53ceac40d0a67551c618b11809f3f8", 202 160 "spec/acceptance/build_csv.rb": "f28ef587de764ade1513091c4906412c", 203 "spec/acceptance/capitalize_spec.rb": "4bb6471ec3a8a07260da8e249fae6ccd", 204 "spec/acceptance/ceiling_spec.rb": "46489eef94aa21bb1560383bb17d7d02", 205 "spec/acceptance/chomp_spec.rb": "8372fe8a875b1a599a89df1191f43bc0", 206 "spec/acceptance/chop_spec.rb": "d73d1c7c6a44df65677362bd2899bbc1", 207 "spec/acceptance/clamp_spec.rb": "8afaae07bf89e0af35474da489fd590f", 208 "spec/acceptance/concat_spec.rb": "bad5f40e0a501b436ec4264cd278290b", 209 "spec/acceptance/count_spec.rb": "f8abd435b077edd06ad76a96a2e610c0", 210 "spec/acceptance/deep_merge_spec.rb": "5f16342cb8c1b52d6a08717a2ef87117", 211 "spec/acceptance/defined_with_params_spec.rb": "8b47a7255b9d662009217f3cfd17ca03", 212 "spec/acceptance/delete_at_spec.rb": "b0c853ffe5fc121e051233d62f6e72b3", 213 "spec/acceptance/delete_spec.rb": "6ccb838a13037a56d1413aecb4fdac00", 214 "spec/acceptance/delete_undef_values_spec.rb": "7d849a978d3ecdaaf5e922acc6038ad8", 215 "spec/acceptance/delete_values_spec.rb": "b9f3dbffbb89fec32c6a5b2bd3b20901", 216 "spec/acceptance/deprecation_spec.rb": "cadc56a94cbc2f13965d698f581f582d", 217 "spec/acceptance/difference_spec.rb": "2f4e8ddd760f2d4dc9a4fb7b653e982f", 218 "spec/acceptance/dirname_spec.rb": "76e6b66474f070d8a89f3fe5bd187e85", 219 "spec/acceptance/downcase_spec.rb": "53f0f5b1867e0fd87ba59833c18b5ca2", 220 "spec/acceptance/empty_spec.rb": "be8a610f87790a321dbd4cc0542e2885", 161 "spec/acceptance/capitalize_spec.rb": "e77ea2c37144a75a67969c0d0839adfd", 162 "spec/acceptance/ceiling_spec.rb": "b2718dc74a39399e342ef96fe0d00fdc", 163 "spec/acceptance/chomp_spec.rb": "fb0862a6b7eeb3c290e280788e705061", 164 "spec/acceptance/chop_spec.rb": "4e7ab2d3a441b88b667a0d8ea5b174c1", 165 "spec/acceptance/clamp_spec.rb": "7513fd2a6701206b4673f40728eae835", 166 "spec/acceptance/concat_spec.rb": "73ce39ffec7184d8ed5f0b5656ed9557", 167 "spec/acceptance/count_spec.rb": "d82cfcad2461b16872455d6347a8b114", 168 "spec/acceptance/deep_merge_spec.rb": "c335a947f1666e185e0210e661f1c78a", 169 "spec/acceptance/defined_with_params_spec.rb": "f27c54ade9872c63c69316f62b03c119", 170 "spec/acceptance/delete_at_spec.rb": "9c028b703ee0286565c9877757678f3f", 171 "spec/acceptance/delete_spec.rb": "31e6dfcb9cc7c16b20d47c00e6a85a1d", 172 "spec/acceptance/delete_undef_values_spec.rb": "6e6a66aee0c383c843b5f92ef8c8410c", 173 "spec/acceptance/delete_values_spec.rb": "22c9b4914d4cbc0153aa3862cb4fb50e", 174 "spec/acceptance/difference_spec.rb": "289f4f1788feaacb304ffd54971c7e7e", 175 "spec/acceptance/dirname_spec.rb": "84db53878c4400a6c684c924cff05cfc", 176 "spec/acceptance/downcase_spec.rb": "0f094849b94a94df491ee01186473104", 177 "spec/acceptance/empty_spec.rb": "e5094267eb1eae007addc5e76b6d43d1", 221 178 "spec/acceptance/ensure_resource_spec.rb": "c0193d79f1db1985d313bedb93a4c7ae", 222 "spec/acceptance/flatten_spec.rb": "3ab1f9c9e761e5d758eeee7a2e32f295", 223 "spec/acceptance/floor_spec.rb": "4a20f6fc7142ef9357c8d18a408b5e52", 224 "spec/acceptance/fqdn_rand_string_spec.rb": "7744b45e282013c5fe637dbaf42f85b9", 225 "spec/acceptance/fqdn_rotate_spec.rb": "366816bb1d3102f64025d61e22eec79c", 226 "spec/acceptance/get_module_path_spec.rb": "d5d2258b2345359d1e51a638b97523cb", 227 "spec/acceptance/getparam_spec.rb": "d4037f1f546cf7a3e7dcabe787e637b5", 228 "spec/acceptance/getvar_spec.rb": "8451bced69bfd5599a552ddf49976d98", 229 "spec/acceptance/grep_spec.rb": "5e6650532658915d1004a6e6c0f1229d", 230 "spec/acceptance/has_interface_with_spec.rb": "e028fc7fc1023293ba32c48c9f46752a", 231 "spec/acceptance/has_ip_address_spec.rb": "f3443be46277f6084ca8e531562d8ac7", 232 "spec/acceptance/has_ip_network_spec.rb": "fa7a38450bef7e4408deb6b978d5a42f", 233 "spec/acceptance/has_key_spec.rb": "68e42fb69d15f27916e7943ab727afc6", 234 "spec/acceptance/hash_spec.rb": "1e8ff803d76d8f9e506c8a366a93ad90", 235 "spec/acceptance/intersection_spec.rb": "755c135f67811666b3c5152c5c5349c2", 236 "spec/acceptance/is_a_spec.rb": "4cdd8df78a6285de21d634c032e5a7c9", 237 "spec/acceptance/is_array_spec.rb": "1de1fb0b55759d4012033ae3ce0723c2", 238 "spec/acceptance/is_bool_spec.rb": "9984cd966d81c217f8ff4e252a4a66d1", 239 "spec/acceptance/is_domain_name_spec.rb": "948dc0c7372027e8f2bb9db85b8d66b2", 240 "spec/acceptance/is_float_spec.rb": "731d9b71e7b4ee5055339d08b2b5f707", 241 "spec/acceptance/is_function_available_spec.rb": "413964bfe8e18c34d8809590afcc4118", 242 "spec/acceptance/is_hash_spec.rb": "9095a364cba82a95a1edd0f92d2218c7", 243 "spec/acceptance/is_integer_spec.rb": "bc4e7192073531638be9f8a4d391a827", 244 "spec/acceptance/is_ip_address_spec.rb": "c2ee8738d62b4c9d42b3ef1a1b8573fc", 245 "spec/acceptance/is_ipv4_address_spec.rb": "09f6f3ad6a1c0a9e5dcfaab34a081ffc", 246 "spec/acceptance/is_ipv6_address_spec.rb": "d19a98176b2b7367e740d338df08c2ae", 247 "spec/acceptance/is_mac_address_spec.rb": "b53f033cc4943a19f597895df0b5210a", 248 "spec/acceptance/is_numeric_spec.rb": "95ecae5adde23e6b61cd090704c4572d", 249 "spec/acceptance/is_string_spec.rb": "d9ad89b30aff62aea4fb805c991c6abf", 250 "spec/acceptance/join_keys_to_values_spec.rb": "908f62013e1d797ddc0ba68c0fb7913b", 251 "spec/acceptance/join_spec.rb": "5609c646859140109af4ae1c63cc69d2", 252 "spec/acceptance/keys_spec.rb": "15edb2f0a5630dfadd9bd6c038e5cf95", 253 "spec/acceptance/loadjson_spec.rb": "7bf8eb220ed02b77e9956dade1acfcb3", 254 "spec/acceptance/loadyaml_spec.rb": "3810faad7411bc1d9c9274671bb68a9a", 255 "spec/acceptance/lstrip_spec.rb": "27a6e2c9e2afc5b3e0e98301798a80ad", 256 "spec/acceptance/max_spec.rb": "c39a2006dacdbd24a8acc5dc25f1a9f3", 257 "spec/acceptance/member_spec.rb": "10b9635c1daf636d66aabea6ff796e6a", 258 "spec/acceptance/merge_spec.rb": "a1502ebd4d069c5f818f7fd8da79e02d", 259 "spec/acceptance/min_spec.rb": "a6e73a33255bc202de93fd8fe679c510", 260 "spec/acceptance/nodesets/centos-7-x64.yml": "a713f3abd3657f0ae2878829badd23cd", 261 "spec/acceptance/nodesets/debian-8-x64.yml": "d2d2977900989f30086ad251a14a1f39", 262 "spec/acceptance/nodesets/default.yml": "b42da5a1ea0c964567ba7495574b8808", 263 "spec/acceptance/nodesets/docker/centos-7.yml": "8a3892807bdd62306ae4774f41ba11ae", 264 "spec/acceptance/nodesets/docker/debian-8.yml": "ac8e871d1068c96de5e85a89daaec6df", 265 "spec/acceptance/nodesets/docker/ubuntu-14.04.yml": "dc42ee922a96908d85b8f0f08203ce58", 266 "spec/acceptance/num2bool_spec.rb": "33ab633c5a6aa1e5e9c0cac9ec23c0d5", 267 "spec/acceptance/parsejson_spec.rb": "56353143de570034f59a87244bb9ff7b", 268 "spec/acceptance/parseyaml_spec.rb": "a564b2217350398d8a3f1b212d0c2ada", 269 "spec/acceptance/pick_default_spec.rb": "bc3512e0cc3bc34da5f44ae18573af5d", 270 "spec/acceptance/pick_spec.rb": "661747652e50bb522ad0c627fb8c3c58", 271 "spec/acceptance/prefix_spec.rb": "2b9df68e18e16144caa4440fd6acaa01", 272 "spec/acceptance/pw_hash_spec.rb": "979f0d209f1ef227a31d27a452fc2ed3", 273 "spec/acceptance/range_spec.rb": "f913a26f4bbe8b9432b6cb80a3b6d1ed", 274 "spec/acceptance/reject_spec.rb": "c63eb909288cf2210f72d3afa1e07b32", 275 "spec/acceptance/reverse_spec.rb": "eca705328f8e246a648e3f62434e662a", 276 "spec/acceptance/rstrip_spec.rb": "bad1e42f66d07b5d09ca1133b392bf6a", 277 "spec/acceptance/shuffle_spec.rb": "adc420bc01d83dde117b04baa4a5e2d8", 278 "spec/acceptance/size_spec.rb": "d923ec158f5c2275b9823dd118edd953", 279 "spec/acceptance/sort_spec.rb": "3ac4acd4233fbe624d926604d58acea6", 280 "spec/acceptance/squeeze_spec.rb": "2270c35766a5162cd732f0f761f0dc34", 281 "spec/acceptance/str2bool_spec.rb": "73ca9cbf9079ef52de10f90cb871e80c", 282 "spec/acceptance/str2saltedsha512_spec.rb": "1e89299c3802ba386589a5133a07dccc", 283 "spec/acceptance/strftime_spec.rb": "6cdfc95c02af2419eb14d173a23df678", 284 "spec/acceptance/strip_spec.rb": "711b6b73fce659ab83956c4454500e55", 285 "spec/acceptance/suffix_spec.rb": "c2ca0539e9e7b71f36ff470d3c18b303", 286 "spec/acceptance/swapcase_spec.rb": "30290d4378f19fa8bac4bc3347a36298", 287 "spec/acceptance/time_spec.rb": "74b6d4f21d46ca612a98efed9c48944c", 288 "spec/acceptance/to_bytes_spec.rb": "ff7d57f85cf1e211b0998235636edfd9", 289 "spec/acceptance/try_get_value_spec.rb": "8b62b969ece6f02c65f0cf3d365324b1", 290 "spec/acceptance/type_spec.rb": "909aa4d0c2463b04a3d3ff72cb0d4b42", 291 "spec/acceptance/union_spec.rb": "41b8705ac890ddd915a5f6c8b33620cd", 292 "spec/acceptance/unique_spec.rb": "0108f76cc12ecb0551a37a002a9bda85", 293 "spec/acceptance/upcase_spec.rb": "30721f352edd513a0cc36c94aa0fe760", 294 "spec/acceptance/uriescape_spec.rb": "69857543c97c35b23094cc6da0828055", 295 "spec/acceptance/validate_absolute_path_spec.rb": "b7f57e45a4d4d2a187bf9db99c481f98", 296 "spec/acceptance/validate_array_spec.rb": "ec0db1f08eb8d64fec1025b65b544365", 297 "spec/acceptance/validate_augeas_spec.rb": "744354dd9726be3624db10935ae2b13f", 298 "spec/acceptance/validate_bool_spec.rb": "950632bafc509e1965cd6a57646d87f6", 299 "spec/acceptance/validate_cmd_spec.rb": "1605939801210b1a53dc8873492551e0", 300 "spec/acceptance/validate_hash_spec.rb": "b79b1ef06301e1b97863281e3c419b0e", 301 "spec/acceptance/validate_ipv4_address_spec.rb": "547520f1ad1d55c52a257f4fb85ecc33", 302 "spec/acceptance/validate_ipv6_address_spec.rb": "feedad9317be19409e351011c7b852b9", 303 "spec/acceptance/validate_re_spec.rb": "bcc18798eccca866883b965baefc3cc9", 304 "spec/acceptance/validate_slength_spec.rb": "29311e9e910bba57a86be9a4893b43e5", 305 "spec/acceptance/validate_string_spec.rb": "cd36b419ebb8630618ec795781081101", 306 "spec/acceptance/values_at_spec.rb": "17e39ac5e094fb05522cb363e12186ab", 307 "spec/acceptance/values_spec.rb": "25d5abaffd9a108a52cdb156b5120e85", 308 "spec/acceptance/zip_spec.rb": "30ac38a83f8e92d642a20b53c5b66292", 309 "spec/aliases/absolute_path_spec.rb": "4326af270230f6d1aef6b1c68a31c53b", 310 "spec/aliases/absolutepath_spec.rb": "ab9a78b2aa5f6eb102ee648c5f88da61", 311 "spec/aliases/array_spec.rb": "09c3559333ec646387e4141ed37d671e", 312 "spec/aliases/bool_spec.rb": "c3f734df3cd334860bba95386b8e8ba6", 313 "spec/aliases/float_spec.rb": "dda76444d67dcf4e9ab4bf8d1a668b23", 314 "spec/aliases/hash_spec.rb": "8b0753fbb41a41655235f999a8cd8a17", 315 "spec/aliases/httpsurl_spec.rb": "49fa0c1da3f055228aaa7ab12471f126", 316 "spec/aliases/httpurl_spec.rb": "fe92b61091197895e9e0070adcaec1e9", 317 "spec/aliases/integer_spec.rb": "3d5c27c864e2385251f1c16a46ef717d", 318 "spec/aliases/ip_address.rb": "297c6577c0763f5121f9ca9c19718dfe", 319 "spec/aliases/ipv4_spec.rb": "8f3be58256671754f32287609c7a64ba", 320 "spec/aliases/ipv6_spec.rb": "68bc3bdf8f2dbb049f8f8daf93d78e82", 321 "spec/aliases/numeric_spec.rb": "a0031bb0085673ec7cc28d9c9b5a72e4", 322 "spec/aliases/string_spec.rb": "8953daa594d54b8efc91fecf73629608", 323 "spec/aliases/unixpath_spec.rb": "1fac6f23e14c3589d26284a081c25c77", 324 "spec/aliases/windowspath_spec.rb": "4a3aec398b2c6ae86cb6d68ac5e8ab06", 325 "spec/fixtures/dscacheutil/root": "e1a7622f55f3d1be258c9a5b16b474be", 326 "spec/fixtures/lsuser/root": "2ed657fa157372a81634539bb1a56be8", 327 "spec/fixtures/test/manifests/absolute_path.pp": "79e9da69f05adc0e1ed41c20bf14e95f", 328 "spec/fixtures/test/manifests/absolutepath.pp": "8561fa141028cd38d0b8409cd69a1372", 329 "spec/fixtures/test/manifests/array.pp": "0e1d4146a9b2dd56063b2cab6f3d7571", 330 "spec/fixtures/test/manifests/bool.pp": "cf75826f36025bd73ff7f479acf7196d", 331 "spec/fixtures/test/manifests/deftype.pp": "b9dbd15e3f4a2dd53aac7f26322abf0c", 332 "spec/fixtures/test/manifests/ensure_resources.pp": "3265ae7af9382cfe7d9a13527265dcc9", 333 "spec/fixtures/test/manifests/float.pp": "132f9a63e60bba2fba68be83208c2e28", 334 "spec/fixtures/test/manifests/hash.pp": "84d647482ef0c7dc35348c13fb0ca23e", 335 "spec/fixtures/test/manifests/httpsurl.pp": "9047fc382d215ae55c065b0798a82a2d", 336 "spec/fixtures/test/manifests/httpurl.pp": "7165bf5607a4808f3da3f9baca911240", 337 "spec/fixtures/test/manifests/integer.pp": "3cb3807714ddcde25cd8eeca61581e3b", 338 "spec/fixtures/test/manifests/ip_address.pp": "78deea27fe1ff9e85c360eced4d2c256", 339 "spec/fixtures/test/manifests/ipv4.pp": "b4f0dfe6ae06d4f8b284d24e55f6a6a2", 340 "spec/fixtures/test/manifests/ipv6.pp": "4764f683b6013556e20d8669b21b5bdc", 341 "spec/fixtures/test/manifests/numeric.pp": "bffd26d7c0bb53628369f42c14b342cb", 342 "spec/fixtures/test/manifests/string.pp": "27b69c1eb36250bfbd474a0ef9ba847b", 343 "spec/fixtures/test/manifests/unixpath.pp": "fd062024efdf731e19026901d3fcc075", 344 "spec/fixtures/test/manifests/windowspath.pp": "7f942ec8f883a3ac0fcaf960ea24b7d8", 179 "spec/acceptance/flatten_spec.rb": "83fb08cc168a105c1d5d0df66b1d9e84", 180 "spec/acceptance/floor_spec.rb": "d7267b2914b1da6406224abb7489ca86", 181 "spec/acceptance/fqdn_rand_string_spec.rb": "45982bd0062e3ffe2dbdd5ef0359d869", 182 "spec/acceptance/fqdn_rotate_spec.rb": "b00226e2ae28acf4ffea8a96b6e64f01", 183 "spec/acceptance/get_module_path_spec.rb": "2658cdcd1abd4b7d20f53c4aced3c72a", 184 "spec/acceptance/getparam_spec.rb": "4d32dc5a0ee34d045242c36d77a3b482", 185 "spec/acceptance/getvar_spec.rb": "ba2f081a88be97c0e7004a6296294f23", 186 "spec/acceptance/grep_spec.rb": "98818b8b0557b80d6ff519f70ea7617c", 187 "spec/acceptance/has_interface_with_spec.rb": "30e27096050c43b7efdb5e6c0d54f53b", 188 "spec/acceptance/has_ip_address_spec.rb": "2812117ec4b88556039e8488d53c0cb0", 189 "spec/acceptance/has_ip_network_spec.rb": "ca75b43ff1256ead9052f2db7620db99", 190 "spec/acceptance/has_key_spec.rb": "6509a26a0886f7d591eaa926b2f92407", 191 "spec/acceptance/hash_spec.rb": "1c626457ba056bdd3936e28aa5bf503e", 192 "spec/acceptance/intersection_spec.rb": "40f586af7f95408a5d4a2882a4aa98f1", 193 "spec/acceptance/is_a_spec.rb": "03e612e76d9004ec625d9e30bb17af04", 194 "spec/acceptance/is_array_spec.rb": "c2ff70ce59b90b50a5aed67abaa5399d", 195 "spec/acceptance/is_bool_spec.rb": "c001fdecff6b0a3c9dc78774987a0b15", 196 "spec/acceptance/is_domain_name_spec.rb": "63e84285c26d8717fd5d4dda01e3f432", 197 "spec/acceptance/is_float_spec.rb": "2f0164b4d732166aa46055a2cf7b4ea9", 198 "spec/acceptance/is_function_available_spec.rb": "7745eba89f8719c9ca7ebf04d5b005f7", 199 "spec/acceptance/is_hash_spec.rb": "cff723cd8fddac45033af5dc8406d4e4", 200 "spec/acceptance/is_integer_spec.rb": "c09201d17d3914bba197872897fa3413", 201 "spec/acceptance/is_ip_address_spec.rb": "aa14cf9abf404c3fe1e761ea957871fe", 202 "spec/acceptance/is_ipv4_address_spec.rb": "b787114912487987801bc68d7cb15142", 203 "spec/acceptance/is_ipv6_address_spec.rb": "c99785448a72f9a2cfa7cd52a392b5e7", 204 "spec/acceptance/is_mac_address_spec.rb": "30ff4c6a63be58daa3568305617ca2a7", 205 "spec/acceptance/is_numeric_spec.rb": "fb9829c7a1a8d4a58836df6ff4c3386d", 206 "spec/acceptance/is_string_spec.rb": "df3022de123b72f0022728eb2d8ce857", 207 "spec/acceptance/join_keys_to_values_spec.rb": "8aa128bbaeea65aab8d92badee3ca2b5", 208 "spec/acceptance/join_spec.rb": "c6378ed481265152bba9871fc5501ee6", 209 "spec/acceptance/keys_spec.rb": "20486e3ebee53e50dc9de3b78b9d6ae6", 210 "spec/acceptance/loadyaml_spec.rb": "bd440cb6779026bd07d83f1aceb2781b", 211 "spec/acceptance/lstrip_spec.rb": "e29ab4039b65660ec2bd76a298adcae0", 212 "spec/acceptance/max_spec.rb": "209cda4b83d677743afb1a8870330618", 213 "spec/acceptance/member_spec.rb": "d6088a4fa6321791a3067d9b9cf8914a", 214 "spec/acceptance/merge_spec.rb": "5f168188fa0d6b31ba5b3dac49fb609c", 215 "spec/acceptance/min_spec.rb": "152a7db28434a0d0378561d4f64cddcc", 216 "spec/acceptance/nodesets/centos-59-x64.yml": "57eb3e471b9042a8ea40978c467f8151", 217 "spec/acceptance/nodesets/centos-6-vcloud.yml": "bdf9ce9d3b0f0b4995666ae9d64d878d", 218 "spec/acceptance/nodesets/centos-64-x64-pe.yml": "ec075d95760df3d4702abea1ce0a829b", 219 "spec/acceptance/nodesets/centos-64-x64.yml": "092dd2c588a9f87fa1fb12997c0723ef", 220 "spec/acceptance/nodesets/centos-65-x64.yml": "3e5c36e6aa5a690229e720f4048bb8af", 221 "spec/acceptance/nodesets/default.yml": "3e5c36e6aa5a690229e720f4048bb8af", 222 "spec/acceptance/nodesets/fedora-18-x64.yml": "80e41b1ee16ea489f53164bfdae58855", 223 "spec/acceptance/nodesets/sles-11-x64.yml": "44e4c6c15c018333bfa9840a5e702f66", 224 "spec/acceptance/nodesets/ubuntu-server-10044-x64.yml": "75e86400b7889888dc0781c0ae1a1297", 225 "spec/acceptance/nodesets/ubuntu-server-12042-x64.yml": "d30d73e34cd50b043c7d14e305955269", 226 "spec/acceptance/nodesets/ubuntu-server-1404-x64.yml": "5f0aed10098ac5b78e4217bb27c7aaf0", 227 "spec/acceptance/nodesets/windows-2003-i386.yml": "b518fc01fab99ee6a9afccec5bc0c1c4", 228 "spec/acceptance/nodesets/windows-2003-x86_64.yml": "5c783eaa8ea4734edc836e89e923dfa1", 229 "spec/acceptance/nodesets/windows-2008-x86_64.yml": "3082234eafcfaf7a9579d9ebdb8bc409", 230 "spec/acceptance/nodesets/windows-2008r2-x86_64.yml": "dfeff32a4cc3fffa872c8281d990a840", 231 "spec/acceptance/nodesets/windows-2012-x86_64.yml": "8bed73362ee1f43d21ea1903a729f955", 232 "spec/acceptance/nodesets/windows-2012r2-x86_64.yml": "3f4f6112d24db02989b8ab79d3a1256f", 233 "spec/acceptance/num2bool_spec.rb": "e4a00b913b08c68a689837e9f9336cb2", 234 "spec/acceptance/parsejson_spec.rb": "5753b9dd66e4fd464c132b39487b922c", 235 "spec/acceptance/parseyaml_spec.rb": "991f6f7b729812535155643c11846bcb", 236 "spec/acceptance/pick_default_spec.rb": "1bc2562380ef6f6cded5ec90a03922be", 237 "spec/acceptance/pick_spec.rb": "272c54c8f9398f499768331bdb4276ee", 238 "spec/acceptance/prefix_spec.rb": "da620568c6771e7d492ec1ff697c531c", 239 "spec/acceptance/pw_hash_spec.rb": "721fe0da04d798a353799fd651bcd0fc", 240 "spec/acceptance/range_spec.rb": "65e5b98ceca257658604d988fbec7d03", 241 "spec/acceptance/reject_spec.rb": "b5185f1a6071c9bdc7aca92e6f899c3e", 242 "spec/acceptance/reverse_spec.rb": "7bdee543e82532e97bbf7a067140031c", 243 "spec/acceptance/rstrip_spec.rb": "28a64ceb7cb5ae8a93d31f49816190ab", 244 "spec/acceptance/shuffle_spec.rb": "8a8652e57d56f2b4946cdf4d20052b7a", 245 "spec/acceptance/size_spec.rb": "ae17d8a55921a0570972200c7c9327e1", 246 "spec/acceptance/sort_spec.rb": "d44b1b8c090f0f00a2f38515fda431ea", 247 "spec/acceptance/squeeze_spec.rb": "adcd65fa4e72203b97f1f14c8835c2cd", 248 "spec/acceptance/str2bool_spec.rb": "55ad165ceef6b9ba32bf20ca3b53b44c", 249 "spec/acceptance/str2saltedsha512_spec.rb": "b684c4214d06ae3d5bae055262a5ccaa", 250 "spec/acceptance/strftime_spec.rb": "0f4eadbd74445b35de4a42c9790fbcc1", 251 "spec/acceptance/strip_spec.rb": "6767da5bc735beb5362aeee6ff692c9e", 252 "spec/acceptance/suffix_spec.rb": "07dfc7eed48b75fcc1b93d0308243eda", 253 "spec/acceptance/swapcase_spec.rb": "5c3c1bc19a09fed6e01881f79b0b4ea5", 254 "spec/acceptance/time_spec.rb": "044b2f634a1fa6ecc735998d68a93b73", 255 "spec/acceptance/to_bytes_spec.rb": "f9df1f234b9409f5eaf56ef24e651c36", 256 "spec/acceptance/try_get_value_spec.rb": "db7c47f372f9d9725987ebe13e6039eb", 257 "spec/acceptance/type_spec.rb": "4297e038a8ff7e6ecb859b8b68c7b3a6", 258 "spec/acceptance/union_spec.rb": "f24e166bc838c9c8cbd75ad3f8f9d15b", 259 "spec/acceptance/unique_spec.rb": "9b00b21cefde3b5391f50eeb9cd2493b", 260 "spec/acceptance/unsupported_spec.rb": "09b9265ecb05252cd5e5a18327c7ae97", 261 "spec/acceptance/upcase_spec.rb": "ffd1d6f9e6ec24131fb78983c53a75f9", 262 "spec/acceptance/uriescape_spec.rb": "13daa387714cbfc63b587aaa8dbf7fcd", 263 "spec/acceptance/validate_absolute_path_spec.rb": "8b9ebfae80329231d84fcab606a3eeaf", 264 "spec/acceptance/validate_array_spec.rb": "382641719e754622ffae562d10e38bf7", 265 "spec/acceptance/validate_augeas_spec.rb": "c26b8ca2184a9dd87033a0c6f0553093", 266 "spec/acceptance/validate_bool_spec.rb": "08bc139459204cf0a35098a5bc30ab95", 267 "spec/acceptance/validate_cmd_spec.rb": "e9260c49d880e4de54f77bf4fd70cff4", 268 "spec/acceptance/validate_hash_spec.rb": "70ceacc18a0dee97b26ab2e50f925706", 269 "spec/acceptance/validate_ipv4_address_spec.rb": "dc901bbd05c3764a93cb49154cea6e4b", 270 "spec/acceptance/validate_ipv6_address_spec.rb": "c0872c56230ac2800cd5723eaa5bc53a", 271 "spec/acceptance/validate_re_spec.rb": "b289909078d6ae0d015419f518566698", 272 "spec/acceptance/validate_slength_spec.rb": "f0a05c1c2b895b096cb7326df4821594", 273 "spec/acceptance/validate_string_spec.rb": "6c9ced99fb1e263e66e25427d24f8f7b", 274 "spec/acceptance/values_at_spec.rb": "669b26c4d47742051472003518c3aa61", 275 "spec/acceptance/values_spec.rb": "9681223bb1bd755c28946ef0bcd6ece9", 276 "spec/acceptance/zip_spec.rb": "86d1b555745ee873da68c71f1e46ed21", 345 277 "spec/functions/abs_spec.rb": "7c0ebbd787b788d32b9bb21fe9061a2f", 346 "spec/functions/any2array_spec.rb": "22b7ce032a34d02b6858360025eb7644", 347 "spec/functions/any2bool_spec.rb": "d090dde9be26601a38980e8f77fa5970", 348 "spec/functions/assert_private_spec.rb": "a7e79ac7a1b28610a0e57e38e913c9fa", 278 "spec/functions/any2array_spec.rb": "c5990164adbaaf4f6536df4022309176", 279 "spec/functions/assert_private_spec.rb": "3bf58bd53467248cc221b9f846b13d98", 349 280 "spec/functions/base64_spec.rb": "fa279d9a4f3060ee3f467e35b050d528", 350 "spec/functions/basename_spec.rb": " 4aec9efc4fc6ed35de82d93b34dc0fab",281 "spec/functions/basename_spec.rb": "84a6567266725376d7ab518ab7dc5fe8", 351 282 "spec/functions/bool2num_spec.rb": "6609136ff067b90d41cf27bf8838c3ea", 352 283 "spec/functions/bool2str_spec.rb": "52560617234393f960aedb496b49a628", … … 354 285 "spec/functions/capitalize_spec.rb": "31a8d497b274653d5ede70a0187d4053", 355 286 "spec/functions/ceiling_spec.rb": "47bd74569f8979d9195df06a863de93b", 356 "spec/functions/chomp_spec.rb": " 8be3a83a34945dcaa6e8e193cf2751e4",357 "spec/functions/chop_spec.rb": " 8e1f661e93dd87b8bbeebe293fe16612",287 "spec/functions/chomp_spec.rb": "6749a0b358b34e73843e1a284cead44a", 288 "spec/functions/chop_spec.rb": "6e33e61f50459191387c87e474d3d127", 358 289 "spec/functions/clamp_spec.rb": "65dab1e9aceb2cb4e41ef9c0c65a7ba3", 359 "spec/functions/concat_spec.rb": " 4161a254ff4c21497e61a62ce84dafe8",290 "spec/functions/concat_spec.rb": "d217a63169e819e1ae2445083c248aa6", 360 291 "spec/functions/convert_base_spec.rb": "f031e84b18cb010bc6233be3e4bcff83", 361 "spec/functions/count_spec.rb": "14ab4e4b10fe33d69d0662357cd4bf8b", 362 "spec/functions/deep_merge_spec.rb": "5a4e826aaa0a0c0e4247b72e03bdfbd1", 363 "spec/functions/defined_with_params_spec.rb": "c592e82de04ab45222b36478ee7040e6", 364 "spec/functions/delete_at_spec.rb": "188a3143799bd5cf121982883c7dc1c8", 365 "spec/functions/delete_regex_spec.rb": "c049a3926aded4b6a804f1c824c57d2f", 366 "spec/functions/delete_spec.rb": "d7c589404fdc3a6b65da7ecf1f7e0b02", 367 "spec/functions/delete_undef_values_spec.rb": "a2c138145333e1873ee4bf23d091f86a", 368 "spec/functions/delete_values_spec.rb": "e20b68a589002f1e2b52873d3dbcfb49", 369 "spec/functions/deprecation_spec.rb": "f5d7355b687eaaa15c20fdb214671c2a", 370 "spec/functions/difference_spec.rb": "66ba399c0bace1a131ecdb365e0afd4e", 371 "spec/functions/dig44_spec.rb": "89631bb7282f7d3c9b75d79f48446c65", 372 "spec/functions/dig_spec.rb": "61708160da38852c3c78bc8563e0fcb2", 373 "spec/functions/dirname_spec.rb": "e80baeab6a166284f5069263fb5e37b7", 374 "spec/functions/dos2unix_spec.rb": "d0cfe5fe19d2bf33320e6f47789826c6", 292 "spec/functions/count_spec.rb": "d91a084665ecd902586d26c99d45beed", 293 "spec/functions/deep_merge_spec.rb": "d70a71c7e9363c75224fffd40fc5efdd", 294 "spec/functions/defined_with_params_spec.rb": "9185955113fd14a7b2fbaa0228669d00", 295 "spec/functions/delete_at_spec.rb": "a5443ac5879992af9c4470e59f0355cf", 296 "spec/functions/delete_spec.rb": "2352787d3a93bf863bd6db186d4bcf4f", 297 "spec/functions/delete_undef_values_spec.rb": "6bee6b89a507130a009a9e8b5ef3e130", 298 "spec/functions/delete_values_spec.rb": "0d2d17c0cacd7f3871ea7ab2f5b96d93", 299 "spec/functions/difference_spec.rb": "2caaab5edb42ddc426e65348b12ebcc3", 300 "spec/functions/dig_spec.rb": "60ef76a16c557e7580cd8747c3476f1e", 301 "spec/functions/dirname_spec.rb": "5c905655d551b1956b6c9eda4ee96569", 302 "spec/functions/dos2unix_spec.rb": "95c13597be9e67e79e69ed0e6c3d325a", 375 303 "spec/functions/downcase_spec.rb": "e2c24d41c6fb840f7b66c5205c942780", 376 304 "spec/functions/empty_spec.rb": "e6d06c193869ce8c97d3e67d5c5c5b4f", 377 "spec/functions/ensure_packages_spec.rb": " cb741ab1e99e7ad9057eea258730cd19",378 "spec/functions/ensure_resource_spec.rb": " e1ebbf9475781d86b58541a5846eda0b",379 "spec/functions/flatten_spec.rb": " 5d59251fa8da0e4c8a376a513a25bc7a",305 "spec/functions/ensure_packages_spec.rb": "76e89bf81ae98e52d2a07263c0e8d4f4", 306 "spec/functions/ensure_resource_spec.rb": "57634d7b6f86ac77dc47fb5da36410c2", 307 "spec/functions/flatten_spec.rb": "6fb563c36daf40599a414c1f3af8dc0b", 380 308 "spec/functions/floor_spec.rb": "7d110b1f994432e1c6c7c004a3dedbe4", 381 "spec/functions/fqdn_rand_string_spec.rb": "950a33e5ad8056fbfe564ec7e3b9a583", 382 "spec/functions/fqdn_rotate_spec.rb": "83f00ce0c48dec632e1aaa8192bb51cf", 383 "spec/functions/fqdn_uuid_spec.rb": "1b2980fcbecc4b51bdc6de01e9b001b7", 309 "spec/functions/fqdn_rand_string_spec.rb": "2edaae1764df4d751684d8ceda7b9cda", 310 "spec/functions/fqdn_rotate_spec.rb": "e9b1ce122788f18611cf64696d666328", 384 311 "spec/functions/get_module_path_spec.rb": "ef22bd80ce5dedb069830d5aa10572c1", 385 "spec/functions/getparam_spec.rb": "359d7c9349ec0e5666bb38e2d9224621", 386 "spec/functions/getvar_spec.rb": "3c7884e012bdb596df3d0640533dab96", 387 "spec/functions/glob_spec.rb": "98e054f995a0d38002d9373b5e6acbc0", 388 "spec/functions/grep_spec.rb": "0e917284860c5f96fdf56301012ba199", 312 "spec/functions/getparam_spec.rb": "dbbdde0a72653feb479e9fb971b94ec7", 313 "spec/functions/getvar_spec.rb": "18a9340442dd59cea8a6c98e95d38f4d", 314 "spec/functions/grep_spec.rb": "b9d0722e7708351b0114c46d4272f760", 389 315 "spec/functions/has_interface_with_spec.rb": "473c000e461c3497f8461eb17cf73430", 390 316 "spec/functions/has_ip_address_spec.rb": "7b36b993ea32757e74be9909906bd165", 391 "spec/functions/has_ip_network_spec.rb": " 7086a27623ba91c5ff069397a32172c4",392 "spec/functions/has_key_spec.rb": " eaa046db8632d6f76893e4b9df7b3e31",393 "spec/functions/hash_spec.rb": " 53a059e13781fac6b4f8eb660655d58f",394 "spec/functions/intersection_spec.rb": " e906cb8ceb39b644b4b338adcd4dda26",395 "spec/functions/is_a_spec.rb": " 7d6322426d629e5302c52455d9c4cd55",396 "spec/functions/is_array_spec.rb": " 26d7eab025f333d2c4a8baf89ef4e36e",397 "spec/functions/is_bool_spec.rb": " 40569a4cdb50af0cc21ad749ac18e6ef",317 "spec/functions/has_ip_network_spec.rb": "23021acd604dc4ca3a1fef62e8863d8e", 318 "spec/functions/has_key_spec.rb": "6bc81bc7d179d4b680e7065a60b76562", 319 "spec/functions/hash_spec.rb": "4519b75eeb8eb0bba80b4594c297cf5e", 320 "spec/functions/intersection_spec.rb": "fcd475963335b3efee99c3ddd0ddd969", 321 "spec/functions/is_a_spec.rb": "51b1f473786fbd1d723febf20281de23", 322 "spec/functions/is_array_spec.rb": "7ea00635b395f231fce6467c95410b05", 323 "spec/functions/is_bool_spec.rb": "9173b8fd7cb5aea4504f0fa860d883c9", 398 324 "spec/functions/is_domain_name_spec.rb": "4ea3825d5b77a5d75eab8228dcc738f9", 399 325 "spec/functions/is_email_address_spec.rb": "699c4573dfd00db8993a18afc0eaf875", 400 "spec/functions/is_float_spec.rb": " 8aedd9e622cd1b861d99523532dc4fc1",326 "spec/functions/is_float_spec.rb": "42b7f071e02af58e3154643b84445af1", 401 327 "spec/functions/is_function_available.rb": "f8ab234d536532c3629ff6a5068e7877", 402 328 "spec/functions/is_hash_spec.rb": "11563529f0f1f821769edb3131277100", 403 "spec/functions/is_integer_spec.rb": "21a139f9a87b1561bfec60de26c435a2", 404 "spec/functions/is_ip_address_spec.rb": "04a15328803bb47ae431eff63aa555df", 405 "spec/functions/is_ipv4_address_spec.rb": "339b8c79925bb70c0de19468d58ab64a", 406 "spec/functions/is_ipv6_address_spec.rb": "9743a0f2bfda70ace128d2f476a208b9", 407 "spec/functions/is_mac_address_spec.rb": "532b8c4c63b37849e7fb9122d163ae3a", 408 "spec/functions/is_numeric_spec.rb": "cb846f44e8f6d79161686d7b3729967c", 409 "spec/functions/is_string_spec.rb": "56f34694781dfcf774e43bca06057fec", 410 "spec/functions/join_keys_to_values_spec.rb": "f99dff6550fdb7c245ed4dcaca0a16a3", 411 "spec/functions/join_spec.rb": "e190fbce526b3f4f7bb8aac029338ece", 412 "spec/functions/keys_spec.rb": "fba0bfa928b5684d5c918d6c06edd06d", 413 "spec/functions/length.rb": "c07a267ccccc4b4edbbfad155dc21475", 414 "spec/functions/load_module_metadata_spec.rb": "431fbe84d627a5c4398f432caaec96f8", 415 "spec/functions/loadjson_spec.rb": "76cbe175c90a596892b799d8e4d599e5", 416 "spec/functions/loadyaml_spec.rb": "60e283bc07adc67bc2c934424bf01b8d", 417 "spec/functions/lstrip_spec.rb": "892229ce8657490c72fc860fb0dda1b6", 329 "spec/functions/is_integer_spec.rb": "799bef092df12fa590e71473db957d11", 330 "spec/functions/is_ip_address_spec.rb": "195e89d0c32eae24e4a51d12b8c59009", 331 "spec/functions/is_mac_address_spec.rb": "748b7e3dffae6d4097da9cc29a37e94d", 332 "spec/functions/is_numeric_spec.rb": "d131e94cf670075e8c46576b5109c2b6", 333 "spec/functions/is_string_spec.rb": "f41f332f93fc05b57ee9611cdbe73c11", 334 "spec/functions/join_keys_to_values_spec.rb": "b95f8f32888a96c4239c87cf9785d288", 335 "spec/functions/join_spec.rb": "2181956bf08efe90f932a17e5138a25c", 336 "spec/functions/keys_spec.rb": "8a6772daf2ae821e98d392f5266fdf67", 337 "spec/functions/load_module_metadata_spec.rb": "bcc48736e28992853c4f6b16d397daed", 338 "spec/functions/loadyaml_spec.rb": "f4f50af8016ffd187a0358b78634a259", 339 "spec/functions/lstrip_spec.rb": "58644ca945b38ec8b3d8729423aacf69", 418 340 "spec/functions/max_spec.rb": "47de8d59070d8d51b2184731f5d1aa43", 419 "spec/functions/member_spec.rb": " 6a988e6368c1ce090b47fe41efbc041c",341 "spec/functions/member_spec.rb": "02891f40caaca15a5aba43443c7d2ccb", 420 342 "spec/functions/merge_spec.rb": "56297527d192640bbe82c7ccf1e39815", 421 343 "spec/functions/min_spec.rb": "8b38e2a989912406cd2c57dcd3a460c4", 422 344 "spec/functions/num2bool_spec.rb": "7c4fd30e41a11b1bd0d9e5233340f16b", 423 "spec/functions/parsejson_spec.rb": " 958db1dde2f2244f458c399e0c3231e0",424 "spec/functions/parseyaml_spec.rb": " 19a2add90ca08d5a17c4e3aff89fe3c0",425 "spec/functions/pick_default_spec.rb": " ab9ef2e9111cfd2709313e0e3c3befa2",426 "spec/functions/pick_spec.rb": " 786044a71e3bd673212949c12f37b10f",427 "spec/functions/prefix_spec.rb": " 2402d2ad5108050bb5c20b3ea58b64be",345 "spec/functions/parsejson_spec.rb": "656300186e986725982595c262f7eccd", 346 "spec/functions/parseyaml_spec.rb": "67b3be346368a2070535585a51bcd7c2", 347 "spec/functions/pick_default_spec.rb": "bef7bb2f755e665775aa0085c6897fb2", 348 "spec/functions/pick_spec.rb": "8fe02695ea909e993119254accc61f1a", 349 "spec/functions/prefix_spec.rb": "95956321291a0f6d1e2f45572569fe3b", 428 350 "spec/functions/private_spec.rb": "f404771c4590a0cd7ce61ddff8f3eb7b", 429 351 "spec/functions/pw_hash_spec.rb": "640609cc73b4c8bbcdfc88c3e9797664", 430 "spec/functions/range_spec.rb": "d3af56cc8a137059423f8738e343ccff", 431 "spec/functions/regexpescape_spec.rb": "ce027e1b99674f39de8ddffcfed8396e", 432 "spec/functions/reject_spec.rb": "8ecbca64a9817ebef76be96dcf6cdeeb", 433 "spec/functions/reverse_spec.rb": "e40754fd34e96ac206308958504ae315", 434 "spec/functions/rstrip_spec.rb": "748f4587c12b5a590b985f111e282a8d", 435 "spec/functions/seeded_rand_spec.rb": "eb56445d10962d81ed935b53826da349", 436 "spec/functions/shell_escape_spec.rb": "bf108573c041f0c228f6d47d367d0aa3", 437 "spec/functions/shell_join_spec.rb": "92f31bd98d6e8e30e5f758f50bcb8a75", 438 "spec/functions/shell_split_spec.rb": "430f58733cc7855e56bfc918971b3fc1", 439 "spec/functions/shuffle_spec.rb": "be5d43184f2ca42db4f452085a4730fd", 440 "spec/functions/size_spec.rb": "f5e35878331bb12d9639522e38cc81c8", 352 "spec/functions/range_spec.rb": "e73c3bb7f2c25540780c3bad19b30994", 353 "spec/functions/reject_spec.rb": "e0eb0546885dd0aef023dfa4694155db", 354 "spec/functions/reverse_spec.rb": "cb48f198c2a9efe224a00d67e68d978f", 355 "spec/functions/rstrip_spec.rb": "f0391a775d335e2a5c9335d50c657f4b", 356 "spec/functions/seeded_rand_spec.rb": "d7d80c3458706e83a8087e17c8a7b6ab", 357 "spec/functions/shuffle_spec.rb": "6ab6083720cfd4dfa99556e5ef81f576", 358 "spec/functions/size_spec.rb": "51495c464a203d9e1919008209f05cd5", 441 359 "spec/functions/sort_spec.rb": "d9533dd37c6263b92895f7eba8485248", 442 "spec/functions/squeeze_spec.rb": " ffcf3b44cbdd45e14eb1173d2b7d1d99",360 "spec/functions/squeeze_spec.rb": "549af334b7f9dd5f06d6b45c3e3e8303", 443 361 "spec/functions/str2bool_spec.rb": "607b25fb0badd0da5acb86c63437c8be", 444 362 "spec/functions/str2saltedsha512_spec.rb": "07586b0026757cd39229c12c7221808b", 445 363 "spec/functions/strftime_spec.rb": "f1a34fc930940213abfba3095d5d8065", 446 "spec/functions/strip_spec.rb": "0 23132b8bd0820da254f74c6fe31bb80",447 "spec/functions/suffix_spec.rb": " dfe26a61bf0185291b6ae868e9d0de20",364 "spec/functions/strip_spec.rb": "0cb8537f2e7df14f42247349ab3161a6", 365 "spec/functions/suffix_spec.rb": "65172f6879c902802230f718ea9df7da", 448 366 "spec/functions/swapcase_spec.rb": "90bace1b004aa63d46eb6481c6dce2b1", 449 367 "spec/functions/time_spec.rb": "6dc8f5b42cf89345d2de424bfe19be90", … … 453 371 "spec/functions/type_of_spec.rb": "83755d9390b9c00e086a007edff7fd9b", 454 372 "spec/functions/type_spec.rb": "7a61b4af7d3d83be590d783a7e5e80f8", 455 "spec/functions/union_spec.rb": " a290a38e443b856a476d14d4b1dc72fb",456 "spec/functions/unique_spec.rb": " 97fbcc73a0e0d82e23c723837627c712",373 "spec/functions/union_spec.rb": "089b03e9a6ef25cdcf68157bb986d8a8", 374 "spec/functions/unique_spec.rb": "b793c531b4d227ae55d05a187b706fb8", 457 375 "spec/functions/unix2dos_spec.rb": "628c8a0c608d1fa0dd09bd1b5af97c1f", 458 376 "spec/functions/upcase_spec.rb": "4f0461a20c03d618f0c18da39bebcf65", 459 377 "spec/functions/uriescape_spec.rb": "1458afbe7e7e11dcaad8d295a7f2be59", 460 "spec/functions/validate_absolute_path_spec.rb": " 5adbf0a0ac8b23e86195deaf3e4bd371",461 "spec/functions/validate_array_spec.rb": " 3aa76f3731754c637acc94b59c79efb0",378 "spec/functions/validate_absolute_path_spec.rb": "26e00ce6122016b9b53797806e681682", 379 "spec/functions/validate_array_spec.rb": "df0bcf372b3efdd1f4de16b508987616", 462 380 "spec/functions/validate_augeas_spec.rb": "d598e89a23912be9f24d39b809f30b47", 463 "spec/functions/validate_bool_spec.rb": " d1b43cd294d0588ac6d67d5d3c77a42a",464 "spec/functions/validate_cmd_spec.rb": " 34a4e623ab0ce7d4c218a837f896c1ea",381 "spec/functions/validate_bool_spec.rb": "93cfbecbe8cc4707ada13f48f5c8c8a6", 382 "spec/functions/validate_cmd_spec.rb": "05eb581532fc689ff91212413b2e678d", 465 383 "spec/functions/validate_email_address_spec.rb": "1296f9934d102258091379ee07f9a2a8", 466 "spec/functions/validate_hash_spec.rb": "0b3ac3f7262f13ef14e3df937c8d104c", 467 "spec/functions/validate_integer_spec.rb": "ec55ab34e3ec4f09722349cd6aac77a6", 468 "spec/functions/validate_ip_address_spec.rb": "ba8c92e30f1af9e6839a2901e002c3f3", 469 "spec/functions/validate_ipv4_address_spec.rb": "d5d956651629f95ea531ac03b71e247b", 470 "spec/functions/validate_ipv6_address_spec.rb": "7ee0d6097666558d8627de424c26ef75", 471 "spec/functions/validate_legacy_spec.rb": "a1a3af70e71d0a6b848d75c518949b3b", 472 "spec/functions/validate_numeric_spec.rb": "c2f01b9c9aeae75683563ef7d3951bbb", 473 "spec/functions/validate_re_spec.rb": "27bcf99cd815b755548cd3979753b2f3", 474 "spec/functions/validate_slength_spec.rb": "c292023b2e61298499ff1f791fc03005", 475 "spec/functions/validate_string_spec.rb": "bc6735359ada0b3ccf69f515231e3808", 384 "spec/functions/validate_hash_spec.rb": "56f4b7e42a4d3f62172982fa639f5cc3", 385 "spec/functions/validate_integer_spec.rb": "0a2677479c8bf0257bdd54c3d0db1f81", 386 "spec/functions/validate_ip_address_spec.rb": "e4ba65ff0c87b28b29f05e1637b7e700", 387 "spec/functions/validate_ipv4_address_spec.rb": "dc1af709faa724ccc51d9c5aba1d6356", 388 "spec/functions/validate_ipv6_address_spec.rb": "5f27c395b286385c489df5ee119580bc", 389 "spec/functions/validate_numeric_spec.rb": "dd5fcc7421002c85252d0a9421a5a99b", 390 "spec/functions/validate_re_spec.rb": "430e57fd80d3f29f4ba8be62c5463e62", 391 "spec/functions/validate_slength_spec.rb": "92252419e0d311a7bd6b426edb3c1040", 392 "spec/functions/validate_string_spec.rb": "779473e87660081e610c397f0157331a", 476 393 "spec/functions/validate_x509_rsa_key_pair_spec.rb": "24810bdb8ac473ae1168f1b2c5708170", 477 "spec/functions/values_at_spec.rb": " 866ba43a4b606f6e9e72ac91c07408bd",478 "spec/functions/values_spec.rb": " 6b8f39665cb8fdb03658d838e50b55b0",479 "spec/functions/zip_spec.rb": " 986defd43a001ff28fe7c90b0366812e",394 "spec/functions/values_at_spec.rb": "c318f66de43f8e6095d28f733f55ec5d", 395 "spec/functions/values_spec.rb": "5550da71a69514f8be87a12b575d5228", 396 "spec/functions/zip_spec.rb": "4c991f26985096b3e8b336cef528aa00", 480 397 "spec/monkey_patches/alias_should_to_must.rb": "b19ee31563afb91a72f9869f9d7362ff", 481 398 "spec/monkey_patches/publicize_methods.rb": "c690e444b77c871375d321e413e28ca1", 482 399 "spec/spec_helper.rb": "b2db3bc02b4ac2fd5142a6621c641b07", 483 "spec/spec_helper_acceptance.rb": "cd589056b52031da19d9c31ed86ea922", 484 "spec/spec_helper_local.rb": "1e3ad3c06a11cbcb813dc1d31973cbda", 485 "spec/support/shared_data.rb": "9758f8ba2958965d287387a2513dac73", 486 "spec/unit/ensure_resources_spec.rb": "30cad259a3cc6c73f90209804183c818", 400 "spec/spec_helper_acceptance.rb": "4da340042246df9b9e3dc221a5807528", 401 "spec/spec_helper_local.rb": "845be3a017611728b73e73af427f7431", 487 402 "spec/unit/facter/facter_dot_d_spec.rb": "420339a544851f2c7ee6fa4c651bdce8", 488 403 "spec/unit/facter/package_provider_spec.rb": "3a6ba799822fbcabc9adab5880260b7a", … … 493 408 "spec/unit/puppet/parser/functions/enclose_ipv6_spec.rb": "0145a78254ea716e5e7600d9464318a8", 494 409 "spec/unit/puppet/parser/functions/is_absolute_path_spec.rb": "52f8d3b9011fb1fd8a2a429fe8b2ae08", 495 "spec/unit/puppet/provider/file_line/ruby_spec.rb": " d269e18953fc297786a8393b20842abc",410 "spec/unit/puppet/provider/file_line/ruby_spec.rb": "e70f3093b17aeccef198b52901ab2f94", 496 411 "spec/unit/puppet/type/anchor_spec.rb": "06a669dffa44d716bf19b4e7f5f1d75d", 497 "spec/unit/puppet/type/file_line_spec.rb": "83e11166de4abe69cdf0dc7450e79778", 498 "types/absolutepath.pp": "3ae6f48dd95835df87c5dacea13c88d2", 499 "types/compat/absolute_path.pp": "6d0e102d1098d85d97c8f13051cb2c10", 500 "types/compat/array.pp": "43c41022dd743d55c8e9e82ce3ed741c", 501 "types/compat/bool.pp": "6e0cd7b2a7e1b9efaa0e273937211e58", 502 "types/compat/float.pp": "fd134a0e0e1abd420cec2107780a7afa", 503 "types/compat/hash.pp": "3535d98f0f3eaec44d443190f258e9ba", 504 "types/compat/integer.pp": "e85a20e42b3afaf5ec0718a8d9f9c5e3", 505 "types/compat/ip_address.pp": "d42c7435de30a469a71b69c45d642da7", 506 "types/compat/ipv4.pp": "c84eb3764f45b256a09be68afe61b749", 507 "types/compat/ipv6.pp": "d3c0fada5425d576aeca14ddbee78653", 508 "types/compat/numeric.pp": "f864539d78e95dabf0bab361b4ccc042", 509 "types/compat/re.pp": "70b05d4697e61f9af0c212ba063f395d", 510 "types/compat/string.pp": "b9a179664c85e121aa0277021627d126", 511 "types/httpsurl.pp": "108225d0273e17d541b239882287ed15", 512 "types/httpurl.pp": "4ba64825b11af75997c59b5acf07c62d", 513 "types/unixpath.pp": "5fc80523e7f474dd84056c44fafd9544", 514 "types/windowspath.pp": "4c1eda331ecb43de98c29ed22d0ad448" 412 "spec/unit/puppet/type/file_line_spec.rb": "af824724caf0071d84464042490a6f88" 515 413 } -
src/puppetcode/environments/gnuboat/modules/stdlib/examples/file_line.pp
rad28f83 rbcf0be5 3 3 file { '/tmp/dansfile': 4 4 ensure => file, 5 } 6 ->file_line { 'dans_line':5 } -> 6 file_line { 'dans_line': 7 7 line => 'dan is awesome', 8 8 path => '/tmp/dansfile', -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/functions/type_of.rb
rad28f83 rbcf0be5 11 11 # See the `assert_type()` function for flexible ways to assert the type of a value. 12 12 # 13 # The built-in type() function in puppet is generally preferred over this function14 # this function is provided for backwards compatibility.15 13 Puppet::Functions.create_function(:type_of) do 16 14 def type_of(value) -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/abs.rb
rad28f83 rbcf0be5 10 10 ) do |arguments| 11 11 12 raise(Puppet::ParseError, "abs(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 12 raise(Puppet::ParseError, "abs(): Wrong number of arguments " + 13 "given (#{arguments.size} for 1)") if arguments.size < 1 13 14 14 15 value = arguments[0] … … 21 22 value = value.to_i 22 23 else 23 raise(Puppet::ParseError, 'abs(): Requires float or integer to work with') 24 raise(Puppet::ParseError, 'abs(): Requires float or ' + 25 'integer to work with') 24 26 end 25 27 end -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/assert_private.rb
rad28f83 rbcf0be5 10 10 ) do |args| 11 11 12 raise(Puppet::ParseError, "assert_private(): Wrong number of arguments given (#{args.size}}) for 0 or 1)") if args.size > 1 12 raise(Puppet::ParseError, "assert_private(): Wrong number of arguments "+ 13 "given (#{args.size}}) for 0 or 1)") if args.size > 1 13 14 14 15 scope = self -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/base64.rb
rad28f83 rbcf0be5 1 2 # Please note: This function is an implementation of a Ruby class and as such may not be entirely UTF8 compatible. To ensure compatibility please use this function with Ruby 2.4.0 or greater - https://bugs.ruby-lang.org/issues/10085.3 4 1 module Puppet::Parser::Functions 5 2 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/bool2num.rb
rad28f83 rbcf0be5 12 12 ) do |arguments| 13 13 14 raise(Puppet::ParseError, "bool2num(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 14 raise(Puppet::ParseError, "bool2num(): Wrong number of arguments " + 15 "given (#{arguments.size} for 1)") if arguments.size < 1 15 16 16 17 value = function_str2bool([arguments[0]]) -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/bool2str.rb
rad28f83 rbcf0be5 21 21 22 22 unless arguments.size == 1 or arguments.size == 3 23 raise(Puppet::ParseError, "bool2str(): Wrong number of arguments given (#{arguments.size} for 3)") 23 raise(Puppet::ParseError, "bool2str(): Wrong number of arguments " + 24 "given (#{arguments.size} for 3)") 24 25 end 25 26 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/camelcase.rb
rad28f83 rbcf0be5 1 1 # 2 2 # camelcase.rb 3 # Please note: This function is an implementation of a Ruby class and as such may not be entirely UTF8 compatible. To ensure compatibility please use this function with Ruby 2.4.0 or greater - https://bugs.ruby-lang.org/issues/10085.4 3 # 5 4 … … 10 9 ) do |arguments| 11 10 12 raise(Puppet::ParseError, "camelcase(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 11 raise(Puppet::ParseError, "camelcase(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size < 1 13 13 14 14 value = arguments[0] … … 16 16 17 17 unless [Array, String].include?(klass) 18 raise(Puppet::ParseError, 'camelcase(): Requires either array or string to work with') 18 raise(Puppet::ParseError, 'camelcase(): Requires either ' + 19 'array or string to work with') 19 20 end 20 21 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/capitalize.rb
rad28f83 rbcf0be5 1 1 # 2 2 # capitalize.rb 3 # Please note: This function is an implementation of a Ruby class and as such may not be entirely UTF8 compatible. To ensure compatibility please use this function with Ruby 2.4.0 or greater - https://bugs.ruby-lang.org/issues/10085.4 3 # 5 4 … … 11 10 ) do |arguments| 12 11 13 raise(Puppet::ParseError, "capitalize(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 12 raise(Puppet::ParseError, "capitalize(): Wrong number of arguments " + 13 "given (#{arguments.size} for 1)") if arguments.size < 1 14 14 15 15 value = arguments[0] 16 16 17 17 unless value.is_a?(Array) || value.is_a?(String) 18 raise(Puppet::ParseError, 'capitalize(): Requires either array or string to work with') 18 raise(Puppet::ParseError, 'capitalize(): Requires either ' + 19 'array or string to work with') 19 20 end 20 21 … … 29 30 end 30 31 end 32 33 # vim: set ts=2 sw=2 et : -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/ceiling.rb
rad28f83 rbcf0be5 6 6 ) do |arguments| 7 7 8 raise(Puppet::ParseError, "ceiling(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size != 1 8 raise(Puppet::ParseError, "ceiling(): Wrong number of arguments " + 9 "given (#{arguments.size} for 1)") if arguments.size != 1 9 10 10 11 begin 11 12 arg = Float(arguments[0]) 12 13 rescue TypeError, ArgumentError => e 13 raise(Puppet::ParseError, "ceiling(): Wrong argument type given (#{arguments[0]} for Numeric)") 14 raise(Puppet::ParseError, "ceiling(): Wrong argument type " + 15 "given (#{arguments[0]} for Numeric)") 14 16 end 15 17 16 raise(Puppet::ParseError, "ceiling(): Wrong argument type given (#{arg.class} for Numeric)") if arg.is_a?(Numeric) == false 18 raise(Puppet::ParseError, "ceiling(): Wrong argument type " + 19 "given (#{arg.class} for Numeric)") if arg.is_a?(Numeric) == false 17 20 18 21 arg.ceil -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/chomp.rb
rad28f83 rbcf0be5 11 11 ) do |arguments| 12 12 13 raise(Puppet::ParseError, "chomp(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 13 raise(Puppet::ParseError, "chomp(): Wrong number of arguments " + 14 "given (#{arguments.size} for 1)") if arguments.size < 1 14 15 15 16 value = arguments[0] 16 17 17 18 unless value.is_a?(Array) || value.is_a?(String) 18 raise(Puppet::ParseError, 'chomp(): Requires either array or string to work with') 19 raise(Puppet::ParseError, 'chomp(): Requires either ' + 20 'array or string to work with') 19 21 end 20 22 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/chop.rb
rad28f83 rbcf0be5 13 13 ) do |arguments| 14 14 15 raise(Puppet::ParseError, "chop(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 15 raise(Puppet::ParseError, "chop(): Wrong number of arguments " + 16 "given (#{arguments.size} for 1)") if arguments.size < 1 16 17 17 18 value = arguments[0] 18 19 19 20 unless value.is_a?(Array) || value.is_a?(String) 20 raise(Puppet::ParseError, 'chop(): Requires either an array or string to work with') 21 raise(Puppet::ParseError, 'chop(): Requires either an ' + 22 'array or string to work with') 21 23 end 22 24 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/clamp.rb
rad28f83 rbcf0be5 11 11 args.flatten! 12 12 13 raise(Puppet::ParseError, 'clamp(): Wrong number of arguments, need three to clamp') if args.size != 3 13 raise(Puppet::ParseError, 'clamp(): Wrong number of arguments, ' + 14 'need three to clamp') if args.size != 3 14 15 15 16 # check values out -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/concat.rb
rad28f83 rbcf0be5 18 18 19 19 # Check that more than 2 arguments have been given ... 20 raise(Puppet::ParseError, "concat(): Wrong number of arguments given (#{arguments.size} for < 2)") if arguments.size < 2 20 raise(Puppet::ParseError, "concat(): Wrong number of arguments " + 21 "given (#{arguments.size} for < 2)") if arguments.size < 2 21 22 22 23 a = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/count.rb
rad28f83 rbcf0be5 8 8 9 9 if (args.size > 2) then 10 raise(ArgumentError, "count(): Wrong number of arguments given #{args.size} for 1 or 2.") 10 raise(ArgumentError, "count(): Wrong number of arguments "+ 11 "given #{args.size} for 1 or 2.") 11 12 end 12 13 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/defined_with_params.rb
rad28f83 rbcf0be5 25 25 end 26 26 ret = false 27 28 if Puppet::Util::Package.versioncmp(Puppet.version, '4.6.0') >= 0 29 # Workaround for PE-20308 30 if reference.is_a?(String) 31 type_name, title = Puppet::Resource.type_and_title(reference, nil) 32 type = Puppet::Pops::Evaluator::Runtime3ResourceSupport.find_resource_type_or_class(find_global_scope, type_name.downcase) 33 elsif reference.is_a?(Puppet::Resource) 34 type = reference.resource_type 35 title = reference.title 36 else 37 raise(ArgumentError, "Reference is not understood: '#{reference.class}'") 38 end 39 #end workaround 40 else 41 type = reference.to_s 42 title = nil 43 end 44 45 if resource = findresource(type, title) 27 if resource = findresource(reference.to_s) 46 28 matches = params.collect do |key, value| 47 # eql? avoids bugs caused by monkeypatching in puppet 48 resource_is_undef = resource[key].eql?(:undef) || resource[key].nil? 49 value_is_undef = value.eql?(:undef) || value.nil? 50 (resource_is_undef && value_is_undef) || (resource[key] == value) 29 resource[key] == value 51 30 end 52 31 ret = params.empty? || !matches.include?(false) -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/delete.rb
rad28f83 rbcf0be5 2 2 # delete.rb 3 3 # 4 5 # TODO(Krzysztof Wilczynski): We need to add support for regular expression ... 4 6 5 7 module Puppet::Parser::Functions … … 24 26 ) do |arguments| 25 27 26 raise(Puppet::ParseError, "delete(): Wrong number of arguments given #{arguments.size} for 2") unless arguments.size == 2 28 if (arguments.size != 2) then 29 raise(Puppet::ParseError, "delete(): Wrong number of arguments "+ 30 "given #{arguments.size} for 2.") 31 end 27 32 28 33 collection = arguments[0].dup … … 34 39 collection.gsub! item, '' 35 40 else 36 raise(TypeError, "delete(): First argument must be an Array, String, or Hash. Given an argument of class #{collection.class}.") 41 raise(TypeError, "delete(): First argument must be an Array, " + 42 "String, or Hash. Given an argument of class #{collection.class}.") 37 43 end 38 44 end -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/delete_at.rb
rad28f83 rbcf0be5 15 15 ) do |arguments| 16 16 17 raise(Puppet::ParseError, "delete_at(): Wrong number of arguments given (#{arguments.size} for 2)") if arguments.size < 2 17 raise(Puppet::ParseError, "delete_at(): Wrong number of arguments " + 18 "given (#{arguments.size} for 2)") if arguments.size < 2 18 19 19 20 array = arguments[0] … … 26 27 27 28 if index.is_a?(String) and not index.match(/^\d+$/) 28 raise(Puppet::ParseError, 'delete_at(): You must provide non-negative numeric index') 29 raise(Puppet::ParseError, 'delete_at(): You must provide ' + 30 'non-negative numeric index') 29 31 end 30 32 … … 35 37 36 38 if index > result.size - 1 # First element is at index 0 is it not? 37 raise(Puppet::ParseError, 'delete_at(): Given index exceeds size of array given') 39 raise(Puppet::ParseError, 'delete_at(): Given index ' + 40 'exceeds size of array given') 38 41 end 39 42 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/delete_undef_values.rb
rad28f83 rbcf0be5 16 16 ) do |args| 17 17 18 raise(Puppet::ParseError, "delete_undef_values(): Wrong number of arguments given (#{args.size})") if args.size < 1 18 raise(Puppet::ParseError, 19 "delete_undef_values(): Wrong number of arguments given " + 20 "(#{args.size})") if args.size < 1 19 21 20 22 unless args[0].is_a? Array or args[0].is_a? Hash 21 raise(Puppet::ParseError, "delete_undef_values(): expected an array or hash, got #{args[0]} type #{args[0].class} ") 23 raise(Puppet::ParseError, 24 "delete_undef_values(): expected an array or hash, got #{args[0]} type #{args[0].class} ") 22 25 end 23 26 result = args[0].dup -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/delete_values.rb
rad28f83 rbcf0be5 12 12 ) do |arguments| 13 13 14 raise(Puppet::ParseError, "delete_values(): Wrong number of arguments given (#{arguments.size} of 2)") if arguments.size != 2 14 raise(Puppet::ParseError, 15 "delete_values(): Wrong number of arguments given " + 16 "(#{arguments.size} of 2)") if arguments.size != 2 15 17 16 18 hash, item = arguments 17 19 18 20 if not hash.is_a?(Hash) 19 raise(TypeError, "delete_values(): First argument must be a Hash. Given an argument of class #{hash.class}.") 21 raise(TypeError, "delete_values(): First argument must be a Hash. " + \ 22 "Given an argument of class #{hash.class}.") 20 23 end 21 24 hash.dup.delete_if { |key, val| item == val } -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/difference.rb
rad28f83 rbcf0be5 18 18 19 19 # Two arguments are required 20 raise(Puppet::ParseError, "difference(): Wrong number of arguments given (#{arguments.size} for 2)") if arguments.size != 2 20 raise(Puppet::ParseError, "difference(): Wrong number of arguments " + 21 "given (#{arguments.size} for 2)") if arguments.size != 2 21 22 22 23 first = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/dig.rb
rad28f83 rbcf0be5 5 5 module Puppet::Parser::Functions 6 6 newfunction(:dig, :type => :rvalue, :doc => <<-EOS 7 DEPRECATED: This function has been replaced in Puppet 4.5.0, please use dig44() for backwards compatibility or use the new version. 7 Looks up into a complex structure of arrays and hashes and returns nil 8 or the default value if nothing was found. 9 10 Path is an array of keys to be looked up in data argument. The function 11 will go down the structure and try to extract the required value. 12 13 $data = { 14 'a' => { 15 'b' => [ 16 'b1', 17 'b2', 18 'b3' ]}} 19 20 $value = dig($data, ['a', 'b', '2'], 'not_found') 21 => $value = 'b3' 22 23 a -> first hash key 24 b -> second hash key 25 2 -> array index starting with 0 26 27 not_found -> (optional) will be returned if there is no value or the path 28 did not match. Defaults to nil. 29 30 In addition to the required "path" argument, "dig" accepts default 31 argument. It will be returned if no value was found or a path component is 32 missing. And the fourth argument can set a variable path separator. 8 33 EOS 9 ) do |arguments| 10 warning("dig() DEPRECATED: This function has been replaced in Puppet 4.5.0, please use dig44() for backwards compatibility or use the new version.") 11 if ! Puppet::Parser::Functions.autoloader.loaded?(:dig44) 12 Puppet::Parser::Functions.autoloader.load(:dig44) 34 ) do |arguments| 35 # Two arguments are required 36 raise(Puppet::ParseError, "dig(): Wrong number of arguments " + 37 "given (#{arguments.size} for at least 2)") if arguments.size < 2 38 39 data, path, default = *arguments 40 41 if !(data.is_a?(Hash) || data.is_a?(Array)) 42 raise(Puppet::ParseError, "dig(): first argument must be a hash or an array, " << 43 "given #{data.class.name}") 13 44 end 14 function_dig44(arguments) 45 46 unless path.is_a? Array 47 raise(Puppet::ParseError, "dig(): second argument must be an array, " << 48 "given #{path.class.name}") 49 end 50 51 value = path.reduce(data) { |h, k| (h.is_a?(Hash) || h.is_a?(Array)) ? h[k] : break } 52 value.nil? ? default : value 15 53 end 16 54 end -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/downcase.rb
rad28f83 rbcf0be5 1 1 # 2 2 # downcase.rb 3 # Please note: This function is an implementation of a Ruby class and as such may not be entirely UTF8 compatible. To ensure compatibility please use this function with Ruby 2.4.0 or greater - https://bugs.ruby-lang.org/issues/10085.4 3 # 5 4 … … 10 9 ) do |arguments| 11 10 12 raise(Puppet::ParseError, "downcase(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 11 raise(Puppet::ParseError, "downcase(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size < 1 13 13 14 14 value = arguments[0] 15 15 16 16 unless value.is_a?(Array) || value.is_a?(String) 17 raise(Puppet::ParseError, 'downcase(): Requires either array or string to work with') 17 raise(Puppet::ParseError, 'downcase(): Requires either ' + 18 'array or string to work with') 18 19 end 19 20 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/empty.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 raise(Puppet::ParseError, "empty(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 11 raise(Puppet::ParseError, "empty(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size < 1 12 13 13 14 value = arguments[0] 14 15 15 16 unless value.is_a?(Array) || value.is_a?(Hash) || value.is_a?(String) || value.is_a?(Numeric) 16 raise(Puppet::ParseError, 'empty(): Requires either array, hash, string or integer to work with') 17 raise(Puppet::ParseError, 'empty(): Requires either ' + 18 'array, hash, string or integer to work with') 17 19 end 18 20 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/enclose_ipv6.rb
rad28f83 rbcf0be5 17 17 18 18 if (arguments.size != 1) then 19 raise(Puppet::ParseError, "enclose_ipv6(): Wrong number of arguments given #{arguments.size} for 1") 19 raise(Puppet::ParseError, "enclose_ipv6(): Wrong number of arguments "+ 20 "given #{arguments.size} for 1") 20 21 end 21 22 unless arguments[0].is_a?(String) or arguments[0].is_a?(Array) then 22 raise(Puppet::ParseError, "enclose_ipv6(): Wrong argument type given #{arguments[0].class} expected String or Array") 23 raise(Puppet::ParseError, "enclose_ipv6(): Wrong argument type "+ 24 "given #{arguments[0].class} expected String or Array") 23 25 end 24 26 … … 31 33 ip = IPAddr.new(val) 32 34 rescue *rescuable_exceptions 33 raise(Puppet::ParseError, "enclose_ipv6(): Wrong argument given #{val} is not an ip address.") 35 raise(Puppet::ParseError, "enclose_ipv6(): Wrong argument "+ 36 "given #{val} is not an ip address.") 34 37 end 35 38 val = "[#{ip.to_s}]" if ip.ipv6? -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/ensure_packages.rb
rad28f83 rbcf0be5 12 12 13 13 if arguments.size > 2 or arguments.size == 0 14 raise(Puppet::ParseError, "ensure_packages(): Wrong number of arguments given (#{arguments.size} for 1 or 2)") 15 elsif arguments.size == 2 and !arguments[1].is_a?(Hash) 14 raise(Puppet::ParseError, "ensure_packages(): Wrong number of arguments " + 15 "given (#{arguments.size} for 1 or 2)") 16 elsif arguments.size == 2 and !arguments[1].is_a?(Hash) 16 17 raise(Puppet::ParseError, 'ensure_packages(): Requires second argument to be a Hash') 17 18 end … … 25 26 26 27 Puppet::Parser::Functions.function(:ensure_resources) 27 function_ensure_resources(['package', arguments[0].dup, defaults ])28 function_ensure_resources(['package', Hash(arguments[0]), defaults ]) 28 29 else 29 30 packages = Array(arguments[0]) … … 37 38 Puppet::Parser::Functions.function(:ensure_resource) 38 39 packages.each { |package_name| 39 raise(Puppet::ParseError, 'ensure_packages(): Empty String provided for package name') if package_name.length == 040 if !findresource("Package[#{package_name}]")41 40 function_ensure_resource(['package', package_name, defaults ]) 42 end43 41 } 44 42 end -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/ensure_resources.rb
rad28f83 rbcf0be5 37 37 38 38 if title.is_a?(Hash) 39 resource_hash = title.dup39 resource_hash = Hash(title) 40 40 resources = resource_hash.keys 41 41 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/flatten.rb
rad28f83 rbcf0be5 16 16 ) do |arguments| 17 17 18 raise(Puppet::ParseError, "flatten(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size != 1 18 raise(Puppet::ParseError, "flatten(): Wrong number of arguments " + 19 "given (#{arguments.size} for 1)") if arguments.size != 1 19 20 20 21 array = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/floor.rb
rad28f83 rbcf0be5 6 6 ) do |arguments| 7 7 8 raise(Puppet::ParseError, "floor(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size != 1 8 raise(Puppet::ParseError, "floor(): Wrong number of arguments " + 9 "given (#{arguments.size} for 1)") if arguments.size != 1 9 10 10 11 begin 11 12 arg = Float(arguments[0]) 12 13 rescue TypeError, ArgumentError => e 13 raise(Puppet::ParseError, "floor(): Wrong argument type given (#{arguments[0]} for Numeric)") 14 raise(Puppet::ParseError, "floor(): Wrong argument type " + 15 "given (#{arguments[0]} for Numeric)") 14 16 end 15 17 16 raise(Puppet::ParseError, "floor(): Wrong argument type given (#{arg.class} for Numeric)") if arg.is_a?(Numeric) == false 18 raise(Puppet::ParseError, "floor(): Wrong argument type " + 19 "given (#{arg.class} for Numeric)") if arg.is_a?(Numeric) == false 17 20 18 21 arg.floor -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/fqdn_rotate.rb
rad28f83 rbcf0be5 16 16 a SEED can be useful if you need more than one unrelated rotation.") do |args| 17 17 18 raise(Puppet::ParseError, "fqdn_rotate(): Wrong number of arguments given (#{args.size} for 1)") if args.size < 1 18 raise(Puppet::ParseError, "fqdn_rotate(): Wrong number of arguments " + 19 "given (#{args.size} for 1)") if args.size < 1 19 20 20 21 value = args.shift … … 22 23 23 24 unless value.is_a?(Array) || value.is_a?(String) 24 raise(Puppet::ParseError, 'fqdn_rotate(): Requires either array or string to work with') 25 raise(Puppet::ParseError, 'fqdn_rotate(): Requires either ' + 26 'array or string to work with') 25 27 end 26 28 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/getparam.rb
rad28f83 rbcf0be5 29 29 30 30 if resource = findresource(reference.to_s) 31 return resource[param] unless resource[param].nil?31 return resource[param] if resource[param] 32 32 end 33 33 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/getvar.rb
rad28f83 rbcf0be5 21 21 22 22 begin 23 result = nil24 23 catch(:undefined_variable) do 25 result =self.lookupvar("#{args[0]}")24 self.lookupvar("#{args[0]}") 26 25 end 27 28 # avoid relying on incosistent behaviour around ruby return values from catch29 result30 26 rescue Puppet::ParseError # Eat the exception if strict_variables = true is set 31 27 end -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/grep.rb
rad28f83 rbcf0be5 19 19 20 20 if (arguments.size != 2) then 21 raise(Puppet::ParseError, "grep(): Wrong number of arguments given #{arguments.size} for 2") 21 raise(Puppet::ParseError, "grep(): Wrong number of arguments "+ 22 "given #{arguments.size} for 2") 22 23 end 23 24 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/has_interface_with.rb
rad28f83 rbcf0be5 20 20 ) do |args| 21 21 22 raise(Puppet::ParseError, "has_interface_with(): Wrong number of arguments given (#{args.size} for 1 or 2)") if args.size < 1 or args.size > 2 22 raise(Puppet::ParseError, "has_interface_with(): Wrong number of arguments " + 23 "given (#{args.size} for 1 or 2)") if args.size < 1 or args.size > 2 23 24 24 25 interfaces = lookupvar('interfaces') -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/has_ip_address.rb
rad28f83 rbcf0be5 12 12 ) do |args| 13 13 14 raise(Puppet::ParseError, "has_ip_address(): Wrong number of arguments given (#{args.size} for 1)") if args.size != 1 14 raise(Puppet::ParseError, "has_ip_address(): Wrong number of arguments " + 15 "given (#{args.size} for 1)") if args.size != 1 15 16 16 17 Puppet::Parser::Functions.autoloader.load(:has_interface_with) \ -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/has_ip_network.rb
rad28f83 rbcf0be5 12 12 ) do |args| 13 13 14 raise(Puppet::ParseError, "has_ip_network(): Wrong number of arguments given (#{args.size} for 1)") if args.size != 1 14 raise(Puppet::ParseError, "has_ip_network(): Wrong number of arguments " + 15 "given (#{args.size} for 1)") if args.size != 1 15 16 16 17 Puppet::Parser::Functions.autoloader.load(:has_interface_with) \ -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/hash.rb
rad28f83 rbcf0be5 15 15 ) do |arguments| 16 16 17 raise(Puppet::ParseError, "hash(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 17 raise(Puppet::ParseError, "hash(): Wrong number of arguments " + 18 "given (#{arguments.size} for 1)") if arguments.size < 1 18 19 19 20 array = arguments[0] … … 30 31 result = Hash[*array] 31 32 rescue StandardError 32 raise(Puppet::ParseError, 'hash(): Unable to compute hash from array given') 33 raise(Puppet::ParseError, 'hash(): Unable to compute ' + 34 'hash from array given') 33 35 end 34 36 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/intersection.rb
rad28f83 rbcf0be5 16 16 17 17 # Two arguments are required 18 raise(Puppet::ParseError, "intersection(): Wrong number of arguments given (#{arguments.size} for 2)") if arguments.size != 2 18 raise(Puppet::ParseError, "intersection(): Wrong number of arguments " + 19 "given (#{arguments.size} for 2)") if arguments.size != 2 19 20 20 21 first = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_absolute_path.rb
rad28f83 rbcf0be5 24 24 25 25 ENDHEREDOC 26 function_deprecation([:is_absolute_path, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Absolute_path. There is further documentation for validate_legacy function in the README.']) 26 27 27 require 'puppet/util' 28 28 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_array.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 function_deprecation([:is_array, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Array. There is further documentation for validate_legacy function in the README.']) 12 13 raise(Puppet::ParseError, "is_array(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 11 raise(Puppet::ParseError, "is_array(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size < 1 14 13 15 14 type = arguments[0] … … 20 19 end 21 20 end 21 22 # vim: set ts=2 sw=2 et : -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_bool.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 function_deprecation([:is_bool, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Bool. There is further documentation for validate_legacy function in the README.']) 12 13 raise(Puppet::ParseError, "is_bool(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size != 1 11 raise(Puppet::ParseError, "is_bool(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size != 1 14 13 15 14 type = arguments[0] … … 20 19 end 21 20 end 21 22 # vim: set ts=2 sw=2 et : -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_domain_name.rb
rad28f83 rbcf0be5 10 10 11 11 if (arguments.size != 1) then 12 raise(Puppet::ParseError, "is_domain_name(): Wrong number of arguments given #{arguments.size} for 1") 12 raise(Puppet::ParseError, "is_domain_name(): Wrong number of arguments "+ 13 "given #{arguments.size} for 1") 13 14 end 14 15 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_email_address.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 if arguments.size != 1 11 raise(Puppet::ParseError, "is_email_address(): Wrong number of arguments given #{arguments.size} for 1") 11 raise(Puppet::ParseError, 'is_email_address(): Wrong number of arguments '\ 12 "given #{arguments.size} for 1") 12 13 end 13 14 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_float.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 function_deprecation([:is_float, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Float. There is further documentation for validate_legacy function in the README.'])12 13 11 if (arguments.size != 1) then 14 raise(Puppet::ParseError, "is_float(): Wrong number of arguments given #{arguments.size} for 1") 12 raise(Puppet::ParseError, "is_float(): Wrong number of arguments "+ 13 "given #{arguments.size} for 1") 15 14 end 16 15 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_function_available.rb
rad28f83 rbcf0be5 12 12 13 13 if (arguments.size != 1) then 14 raise(Puppet::ParseError, "is_function_available?(): Wrong number of arguments given #{arguments.size} for 1") 14 raise(Puppet::ParseError, "is_function_available?(): Wrong number of arguments "+ 15 "given #{arguments.size} for 1") 15 16 end 16 17 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_hash.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 raise(Puppet::ParseError, "is_hash(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size != 1 11 raise(Puppet::ParseError, "is_hash(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size != 1 12 13 13 14 type = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_integer.rb
rad28f83 rbcf0be5 14 14 ) do |arguments| 15 15 16 function_deprecation([:is_integer, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Integer. There is further documentation for validate_legacy function in the README.'])17 18 16 if (arguments.size != 1) then 19 raise(Puppet::ParseError, "is_integer(): Wrong number of arguments given #{arguments.size} for 1") 17 raise(Puppet::ParseError, "is_integer(): Wrong number of arguments "+ 18 "given #{arguments.size} for 1") 20 19 end 21 20 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_ip_address.rb
rad28f83 rbcf0be5 11 11 require 'ipaddr' 12 12 13 function_deprecation([:is_ip_address, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Ip_address. There is further documentation for validate_legacy function in the README.'])14 15 13 if (arguments.size != 1) then 16 raise(Puppet::ParseError, "is_ip_address(): Wrong number of arguments given #{arguments.size} for 1") 14 raise(Puppet::ParseError, "is_ip_address(): Wrong number of arguments "+ 15 "given #{arguments.size} for 1") 17 16 end 18 17 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_ipv4_address.rb
rad28f83 rbcf0be5 11 11 require 'ipaddr' 12 12 13 function_deprecation([:is_ipv4_address, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Ipv4. There is further documentation for validate_legacy function in the README.'])14 15 13 if (arguments.size != 1) then 16 raise(Puppet::ParseError, "is_ipv4_address(): Wrong number of arguments given #{arguments.size} for 1") 14 raise(Puppet::ParseError, "is_ipv4_address(): Wrong number of arguments "+ 15 "given #{arguments.size} for 1") 17 16 end 18 17 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_ipv6_address.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 function_deprecation([:is_ipv6_address, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Ipv6. There is further documentation for validate_legacy function in the README.'])12 13 11 require 'ipaddr' 14 12 15 13 if (arguments.size != 1) then 16 raise(Puppet::ParseError, "is_ipv6_address(): Wrong number of arguments given #{arguments.size} for 1") 14 raise(Puppet::ParseError, "is_ipv6_address(): Wrong number of arguments "+ 15 "given #{arguments.size} for 1") 17 16 end 18 17 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_mac_address.rb
rad28f83 rbcf0be5 10 10 11 11 if (arguments.size != 1) then 12 raise(Puppet::ParseError, "is_mac_address(): Wrong number of arguments given #{arguments.size} for 1") 12 raise(Puppet::ParseError, "is_mac_address(): Wrong number of arguments "+ 13 "given #{arguments.size} for 1") 13 14 end 14 15 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_numeric.rb
rad28f83 rbcf0be5 25 25 ) do |arguments| 26 26 27 function_deprecation([:is_numeric, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Numeric. There is further documentation for validate_legacy function in the README.'])28 29 27 if (arguments.size != 1) then 30 raise(Puppet::ParseError, "is_numeric(): Wrong number of arguments given #{arguments.size} for 1") 28 raise(Puppet::ParseError, "is_numeric(): Wrong number of arguments "+ 29 "given #{arguments.size} for 1") 31 30 end 32 31 … … 73 72 end 74 73 end 74 75 # vim: set ts=2 sw=2 et : -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/is_string.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 function_deprecation([:is_string, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::String. There is further documentation for validate_legacy function in the README.']) 12 13 raise(Puppet::ParseError, "is_string(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 11 raise(Puppet::ParseError, "is_string(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size < 1 14 13 15 14 type = arguments[0] 16 15 17 # when called through the v4 API shim, undef gets translated to nil 18 result = type.is_a?(String) || type.nil? 16 result = type.is_a?(String) 19 17 20 18 if result and (type == type.to_f.to_s or type == type.to_i.to_s) then -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/join.rb
rad28f83 rbcf0be5 16 16 17 17 # Technically we support two arguments but only first is mandatory ... 18 raise(Puppet::ParseError, "join(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 18 raise(Puppet::ParseError, "join(): Wrong number of arguments " + 19 "given (#{arguments.size} for 1)") if arguments.size < 1 19 20 20 21 array = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/join_keys_to_values.rb
rad28f83 rbcf0be5 6 6 newfunction(:join_keys_to_values, :type => :rvalue, :doc => <<-EOS 7 7 This function joins each key of a hash to that key's corresponding value with a 8 separator. Keys are cast to strings. If values are arrays, multiple keys 9 are added for each element. The return value is an array in 8 separator. Keys and values are cast to strings. The return value is an array in 10 9 which each element is one joined key/value pair. 11 10 … … 15 14 16 15 Would result in: ["a is 1","b is 2"] 17 18 join_keys_to_values({'a'=>1,'b'=>[2,3]}, " is ")19 20 Would result in: ["a is 1","b is 2","b is 3"]21 16 EOS 22 17 ) do |arguments| … … 24 19 # Validate the number of arguments. 25 20 if arguments.size != 2 26 raise(Puppet::ParseError, "join_keys_to_values(): Takes exactly two arguments, but #{arguments.size} given.") 21 raise(Puppet::ParseError, "join_keys_to_values(): Takes exactly two " + 22 "arguments, but #{arguments.size} given.") 27 23 end 28 24 … … 30 26 hash = arguments[0] 31 27 if not hash.is_a?(Hash) 32 raise(TypeError, "join_keys_to_values(): The first argument must be a hash, but a #{hash.class} was given.") 28 raise(TypeError, "join_keys_to_values(): The first argument must be a " + 29 "hash, but a #{hash.class} was given.") 33 30 end 34 31 … … 36 33 separator = arguments[1] 37 34 if not separator.is_a?(String) 38 raise(TypeError, "join_keys_to_values(): The second argument must be a string, but a #{separator.class} was given.") 35 raise(TypeError, "join_keys_to_values(): The second argument must be a " + 36 "string, but a #{separator.class} was given.") 39 37 end 40 38 41 39 # Join the keys to their values. 42 40 hash.map do |k,v| 43 if v.is_a?(Array) 44 v.map { |va| String(k) + separator + String(va) } 45 else 46 String(k) + separator + String(v) 47 end 48 end.flatten 41 String(k) + separator + String(v) 42 end 49 43 50 44 end -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/keys.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 raise(Puppet::ParseError, "keys(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 11 raise(Puppet::ParseError, "keys(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size < 1 12 13 13 14 hash = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/loadyaml.rb
rad28f83 rbcf0be5 1 1 module Puppet::Parser::Functions 2 newfunction(:loadyaml, :type => :rvalue, :arity => -2, :doc => <<-'ENDHEREDOC') do |args|3 Load a YAML file containing an array, string, or hash, and return the data4 in the corresponding native data type.5 The second parameter is the default value. It will be returned if the file6 was not found or could not be parsed.7 2 8 For example: 3 newfunction(:loadyaml, :type => :rvalue, :doc => <<-'ENDHEREDOC') do |args| 4 Load a YAML file containing an array, string, or hash, and return the data 5 in the corresponding native data type. 9 6 10 $myhash = loadyaml('/etc/puppet/data/myhash.yaml') 11 $myhash = loadyaml('no-file.yaml', {'default' => 'value'}) 12 ENDHEREDOC 7 For example: 13 8 14 raise ArgumentError, 'Wrong number of arguments. 1 or 2 arguments should be provided.' unless args.length >= 115 require 'yaml'9 $myhash = loadyaml('/etc/puppet/data/myhash.yaml') 10 ENDHEREDOC 16 11 17 if File.exists?(args[0]) 18 begin 19 YAML::load_file(args[0]) || args[1] 20 rescue Exception => e 21 if args[1] 22 args[1] 23 else 24 raise e 25 end 26 end 12 unless args.length == 1 13 raise Puppet::ParseError, ("loadyaml(): wrong number of arguments (#{args.length}; must be 1)") 14 end 15 16 if File.exists?(args[0]) then 17 YAML.load_file(args[0]) 27 18 else 28 warning("Can't load '#{args[0]}'File does not exist!")29 args[1]19 warning("Can't load " + args[0] + ". File does not exist!") 20 nil 30 21 end 31 22 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/lstrip.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 raise(Puppet::ParseError, "lstrip(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 11 raise(Puppet::ParseError, "lstrip(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size < 1 12 13 13 14 value = arguments[0] 14 15 15 16 unless value.is_a?(Array) || value.is_a?(String) 16 raise(Puppet::ParseError, 'lstrip(): Requires either array or string to work with') 17 raise(Puppet::ParseError, 'lstrip(): Requires either ' + 18 'array or string to work with') 17 19 end 18 20 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/max.rb
rad28f83 rbcf0be5 6 6 ) do |args| 7 7 8 raise(Puppet::ParseError, "max(): Wrong number of arguments need at least one") if args.size == 0 8 raise(Puppet::ParseError, "max(): Wrong number of arguments " + 9 "need at least one") if args.size == 0 9 10 10 11 # Sometimes we get numbers as numerics and sometimes as strings. -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/member.rb
rad28f83 rbcf0be5 31 31 ) do |arguments| 32 32 33 raise(Puppet::ParseError, "member(): Wrong number of arguments given (#{arguments.size} for 2)") if arguments.size < 2 33 raise(Puppet::ParseError, "member(): Wrong number of arguments " + 34 "given (#{arguments.size} for 2)") if arguments.size < 2 34 35 35 36 array = arguments[0] … … 50 51 51 52 52 raise(Puppet::ParseError, 'member(): You must provide item to search for within array given') if item.respond_to?('empty?') && item.empty? 53 raise(Puppet::ParseError, 'member(): You must provide item ' + 54 'to search for within array given') if item.respond_to?('empty?') && item.empty? 53 55 54 56 result = (item - array).empty? -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/min.rb
rad28f83 rbcf0be5 6 6 ) do |args| 7 7 8 raise(Puppet::ParseError, "min(): Wrong number of arguments need at least one") if args.size == 0 8 raise(Puppet::ParseError, "min(): Wrong number of arguments " + 9 "need at least one") if args.size == 0 9 10 10 11 # Sometimes we get numbers as numerics and sometimes as strings. -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/num2bool.rb
rad28f83 rbcf0be5 11 11 ) do |arguments| 12 12 13 raise(Puppet::ParseError, "num2bool(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size != 1 13 raise(Puppet::ParseError, "num2bool(): Wrong number of arguments " + 14 "given (#{arguments.size} for 1)") if arguments.size != 1 14 15 15 16 number = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/prefix.rb
rad28f83 rbcf0be5 16 16 17 17 # Technically we support two arguments but only first is mandatory ... 18 raise(Puppet::ParseError, "prefix(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 18 raise(Puppet::ParseError, "prefix(): Wrong number of arguments " + 19 "given (#{arguments.size} for 1)") if arguments.size < 1 19 20 20 21 enumerable = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/pw_hash.rb
rad28f83 rbcf0be5 1 2 # Please note: This function is an implementation of a Ruby class and as such may not be entirely UTF8 compatible. To ensure compatibility please use this function with Ruby 2.4.0 or greater - https://bugs.ruby-lang.org/issues/10085.3 4 1 Puppet::Parser::Functions::newfunction( 5 2 :pw_hash, -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/range.rb
rad28f83 rbcf0be5 26 26 27 27 range("host01", "host10") 28 28 29 Will return: ["host01", "host02", ..., "host09", "host10"] 29 NB Be explicit in including trailing zeros. Otherwise the underlying ruby function will fail.30 30 31 31 Passing a third argument will cause the generated range to step by that … … 38 38 ) do |arguments| 39 39 40 raise(Puppet::ParseError, 'range(): Wrong number of arguments given (0 for 1)') if arguments.size == 0 40 raise(Puppet::ParseError, 'range(): Wrong number of ' + 41 'arguments given (0 for 1)') if arguments.size == 0 41 42 42 43 if arguments.size > 1 … … 57 58 step = 1 58 59 elsif value.match(/^.+$/) 59 raise(Puppet::ParseError, "range(): Unable to compute range from the value: #{value}") 60 raise(Puppet::ParseError, "range(): Unable to compute range " + 61 "from the value: #{value}") 60 62 else 61 63 raise(Puppet::ParseError, "range(): Unknown range format: #{value}") -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/reverse.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 raise(Puppet::ParseError, "reverse(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 11 raise(Puppet::ParseError, "reverse(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size < 1 12 13 13 14 value = arguments[0] 14 15 15 16 unless value.is_a?(Array) || value.is_a?(String) 16 raise(Puppet::ParseError, 'reverse(): Requires either array or string to work with') 17 raise(Puppet::ParseError, 'reverse(): Requires either ' + 18 'array or string to work with') 17 19 end 18 20 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/rstrip.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 raise(Puppet::ParseError, "rstrip(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 11 raise(Puppet::ParseError, "rstrip(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size < 1 12 13 13 14 value = arguments[0] 14 15 15 16 unless value.is_a?(Array) || value.is_a?(String) 16 raise(Puppet::ParseError, 'rstrip(): Requires either array or string to work with') 17 raise(Puppet::ParseError, 'rstrip(): Requires either ' + 18 'array or string to work with') 17 19 end 18 20 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/shuffle.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 raise(Puppet::ParseError, "shuffle(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 11 raise(Puppet::ParseError, "shuffle(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size < 1 12 13 13 14 value = arguments[0] 14 15 15 16 unless value.is_a?(Array) || value.is_a?(String) 16 raise(Puppet::ParseError, 'shuffle(): Requires either array or string to work with') 17 raise(Puppet::ParseError, 'shuffle(): Requires either ' + 18 'array or string to work with') 17 19 end 18 20 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/size.rb
rad28f83 rbcf0be5 9 9 ) do |arguments| 10 10 11 raise(Puppet::ParseError, "size(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 11 raise(Puppet::ParseError, "size(): Wrong number of arguments " + 12 "given (#{arguments.size} for 1)") if arguments.size < 1 12 13 13 14 item = arguments[0] 14 15 function_deprecation([:size, 'This method is going to be deprecated, please use the stdlib length function.'])16 15 17 16 if item.is_a?(String) … … 28 27 Float(item) 29 28 30 raise(Puppet::ParseError, 'size(): Requires either string, array or hash to work with') 29 raise(Puppet::ParseError, 'size(): Requires either ' + 30 'string, array or hash to work with') 31 31 32 32 rescue ArgumentError -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/sort.rb
rad28f83 rbcf0be5 1 1 # 2 # sort.rb 3 # Please note: This function is an implementation of a Ruby class and as such may not be entirely UTF8 compatible. To ensure compatibility please use this function with Ruby 2.4.0 or greater - https://bugs.ruby-lang.org/issues/10085. 2 # sort.rb 4 3 # 5 4 … … 11 10 12 11 if (arguments.size != 1) then 13 raise(Puppet::ParseError, "sort(): Wrong number of arguments given #{arguments.size} for 1") 12 raise(Puppet::ParseError, "sort(): Wrong number of arguments "+ 13 "given #{arguments.size} for 1") 14 14 end 15 15 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/squeeze.rb
rad28f83 rbcf0be5 10 10 11 11 if ((arguments.size != 2) and (arguments.size != 1)) then 12 raise(Puppet::ParseError, "squeeze(): Wrong number of arguments given #{arguments.size} for 2 or 1") 12 raise(Puppet::ParseError, "squeeze(): Wrong number of arguments "+ 13 "given #{arguments.size} for 2 or 1") 13 14 end 14 15 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/str2bool.rb
rad28f83 rbcf0be5 11 11 ) do |arguments| 12 12 13 raise(Puppet::ParseError, "str2bool(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 13 raise(Puppet::ParseError, "str2bool(): Wrong number of arguments " + 14 "given (#{arguments.size} for 1)") if arguments.size < 1 14 15 15 16 string = arguments[0] … … 21 22 22 23 unless string.is_a?(String) 23 raise(Puppet::ParseError, 'str2bool(): Requires string to work with') 24 raise(Puppet::ParseError, 'str2bool(): Requires either ' + 25 'string to work with') 24 26 end 25 27 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/str2saltedsha512.rb
rad28f83 rbcf0be5 1 1 # 2 # str2saltedsha512.rb 3 # Please note: This function is an implementation of a Ruby class and as such may not be entirely UTF8 compatible. To ensure compatibility please use this function with Ruby 2.4.0 or greater - https://bugs.ruby-lang.org/issues/10085. 2 # str2saltedsha512.rb 4 3 # 5 4 … … 14 13 require 'digest/sha2' 15 14 16 raise(Puppet::ParseError, "str2saltedsha512(): Wrong number of arguments passed (#{arguments.size} but we require 1)") if arguments.size != 1 15 raise(Puppet::ParseError, "str2saltedsha512(): Wrong number of arguments " + 16 "passed (#{arguments.size} but we require 1)") if arguments.size != 1 17 17 18 18 password = arguments[0] 19 19 20 20 unless password.is_a?(String) 21 raise(Puppet::ParseError, "str2saltedsha512(): Requires a String argument, you passed: #{password.class}") 21 raise(Puppet::ParseError, 'str2saltedsha512(): Requires a ' + 22 "String argument, you passed: #{password.class}") 22 23 end 23 24 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/strftime.rb
rad28f83 rbcf0be5 1 1 # 2 # strftime.rb 3 # Please note: This function is an implementation of a Ruby class and as such may not be entirely UTF8 compatible. To ensure compatibility please use this function with Ruby 2.4.0 or greater - https://bugs.ruby-lang.org/issues/10085. 2 # strftime.rb 4 3 # 5 4 … … 73 72 74 73 # Technically we support two arguments but only first is mandatory ... 75 raise(Puppet::ParseError, "strftime(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 74 raise(Puppet::ParseError, "strftime(): Wrong number of arguments " + 75 "given (#{arguments.size} for 1)") if arguments.size < 1 76 76 77 77 format = arguments[0] 78 78 79 raise(Puppet::ParseError, 'strftime(): You must provide format for evaluation') if format.empty? 79 raise(Puppet::ParseError, 'strftime(): You must provide ' + 80 'format for evaluation') if format.empty? 80 81 81 82 # The Time Zone argument is optional ... -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/strip.rb
rad28f83 rbcf0be5 16 16 ) do |arguments| 17 17 18 raise(Puppet::ParseError, "strip(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 18 raise(Puppet::ParseError, "strip(): Wrong number of arguments " + 19 "given (#{arguments.size} for 1)") if arguments.size < 1 19 20 20 21 value = arguments[0] 21 22 22 23 unless value.is_a?(Array) || value.is_a?(String) 23 raise(Puppet::ParseError, 'strip(): Requires either array or string to work with') 24 raise(Puppet::ParseError, 'strip(): Requires either ' + 25 'array or string to work with') 24 26 end 25 27 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/suffix.rb
rad28f83 rbcf0be5 17 17 18 18 # Technically we support two arguments but only first is mandatory ... 19 raise(Puppet::ParseError, "suffix(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 19 raise(Puppet::ParseError, "suffix(): Wrong number of arguments " + 20 "given (#{arguments.size} for 1)") if arguments.size < 1 20 21 21 22 enumerable = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/swapcase.rb
rad28f83 rbcf0be5 1 1 # 2 2 # swapcase.rb 3 # Please note: This function is an implementation of a Ruby class and as such may not be entirely UTF8 compatible. To ensure compatibility please use this function with Ruby 2.4.0 or greater - https://bugs.ruby-lang.org/issues/10085.4 3 # 5 4 … … 16 15 ) do |arguments| 17 16 18 raise(Puppet::ParseError, "swapcase(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 17 raise(Puppet::ParseError, "swapcase(): Wrong number of arguments " + 18 "given (#{arguments.size} for 1)") if arguments.size < 1 19 19 20 20 value = arguments[0] 21 21 22 22 unless value.is_a?(Array) || value.is_a?(String) 23 raise(Puppet::ParseError, 'swapcase(): Requires either array or string to work with') 23 raise(Puppet::ParseError, 'swapcase(): Requires either ' + 24 'array or string to work with') 24 25 end 25 26 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/time.rb
rad28f83 rbcf0be5 19 19 20 20 if (arguments.size != 0) and (arguments.size != 1) then 21 raise(Puppet::ParseError, "time(): Wrong number of arguments given #{arguments.size} for 0 or 1") 21 raise(Puppet::ParseError, "time(): Wrong number of arguments "+ 22 "given #{arguments.size} for 0 or 1") 22 23 end 23 24 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/to_bytes.rb
rad28f83 rbcf0be5 8 8 ) do |arguments| 9 9 10 raise(Puppet::ParseError, "to_bytes(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size != 1 10 raise(Puppet::ParseError, "to_bytes(): Wrong number of arguments " + 11 "given (#{arguments.size} for 1)") if arguments.size != 1 11 12 12 13 arg = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/type3x.rb
rad28f83 rbcf0be5 17 17 EOS 18 18 ) do |args| 19 raise(Puppet::ParseError, "type3x(): Wrong number of arguments given (#{args.size} for 1)") if args.size < 1 19 raise(Puppet::ParseError, "type3x(): Wrong number of arguments " + 20 "given (#{args.size} for 1)") if args.size < 1 20 21 21 22 value = args[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/union.rb
rad28f83 rbcf0be5 16 16 17 17 # Check that 2 or more arguments have been given ... 18 raise(Puppet::ParseError, "union(): Wrong number of arguments given (#{arguments.size} for < 2)") if arguments.size < 2 18 raise(Puppet::ParseError, "union(): Wrong number of arguments " + 19 "given (#{arguments.size} for < 2)") if arguments.size < 2 19 20 20 21 arguments.each do |argument| -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/unique.rb
rad28f83 rbcf0be5 25 25 ) do |arguments| 26 26 27 raise(Puppet::ParseError, "unique(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 27 raise(Puppet::ParseError, "unique(): Wrong number of arguments " + 28 "given (#{arguments.size} for 1)") if arguments.size < 1 28 29 29 30 value = arguments[0] 30 31 31 32 unless value.is_a?(Array) || value.is_a?(String) 32 raise(Puppet::ParseError, 'unique(): Requires either array or string to work with') 33 raise(Puppet::ParseError, 'unique(): Requires either ' + 34 'array or string to work with') 33 35 end 34 36 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/upcase.rb
rad28f83 rbcf0be5 1 1 # 2 # upcase.rb 3 # Please note: This function is an implementation of a Ruby class and as such may not be entirely UTF8 compatible. To ensure compatibility please use this function with Ruby 2.4.0 or greater - https://bugs.ruby-lang.org/issues/10085. 2 # upcase.rb 4 3 # 5 4 … … 18 17 ) do |arguments| 19 18 20 raise(Puppet::ParseError, "upcase(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size != 1 19 raise(Puppet::ParseError, "upcase(): Wrong number of arguments " + 20 "given (#{arguments.size} for 1)") if arguments.size != 1 21 21 22 22 value = arguments[0] 23 23 24 24 unless value.is_a?(Array) || value.is_a?(Hash) || value.respond_to?(:upcase) 25 raise(Puppet::ParseError, 'upcase(): Requires an array, hash or object that responds to upcase in order to work') 25 raise(Puppet::ParseError, 'upcase(): Requires an ' + 26 'array, hash or object that responds to upcase in order to work') 26 27 end 27 28 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/uriescape.rb
rad28f83 rbcf0be5 1 1 # 2 2 # uriescape.rb 3 # Please note: This function is an implementation of a Ruby class and as such may not be entirely UTF8 compatible. To ensure compatibility please use this function with Ruby 2.4.0 or greater - https://bugs.ruby-lang.org/issues/10085.4 3 # 5 4 require 'uri' … … 12 11 ) do |arguments| 13 12 14 raise(Puppet::ParseError, "uriescape(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 13 raise(Puppet::ParseError, "uriescape(): Wrong number of arguments " + 14 "given (#{arguments.size} for 1)") if arguments.size < 1 15 15 16 16 value = arguments[0] 17 17 18 18 unless value.is_a?(Array) || value.is_a?(String) 19 raise(Puppet::ParseError, 'uriescape(): Requires either array or string to work with') 19 raise(Puppet::ParseError, 'uriescape(): Requires either ' + 20 'array or string to work with') 20 21 end 21 22 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_absolute_path.rb
rad28f83 rbcf0be5 27 27 ENDHEREDOC 28 28 29 # The deprecation function was being called twice, as validate_absolute_path calls is_absolute_path. I have removed it from here so it only calls deprecation once within is_absolute_path.30 # function_deprecation([:validate_absolute_path, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Absolute_path. There is further documentation for validate_legacy function in the README.'])31 32 29 require 'puppet/util' 33 30 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_array.rb
rad28f83 rbcf0be5 19 19 ENDHEREDOC 20 20 21 function_deprecation([:validate_array, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Array. There is further documentation for validate_legacy function in the README.'])22 23 21 unless args.length > 0 then 24 22 raise Puppet::ParseError, ("validate_array(): wrong number of arguments (#{args.length}; must be > 0)") -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_bool.rb
rad28f83 rbcf0be5 20 20 ENDHEREDOC 21 21 22 # The deprecation function was being called twice, as validate_bool calls is_bool. I have removed it from here so it only calls deprecation once within is_bool.23 # function_deprecation([:validate_bool, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Bool. There is further documentation for validate_legacy function in the README.'])24 25 22 unless args.length > 0 then 26 23 raise Puppet::ParseError, ("validate_bool(): wrong number of arguments (#{args.length}; must be > 0)") -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_email_address.rb
rad28f83 rbcf0be5 1 1 module Puppet::Parser::Functions 2 newfunction(:validate_email_address, :doc =><<-ENDHEREDOC2 newfunction(:validate_email_address, doc: <<-ENDHEREDOC 3 3 Validate that all values passed are valid email addresses. 4 4 Fail compilation if any value fails this check. -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_hash.rb
rad28f83 rbcf0be5 19 19 ENDHEREDOC 20 20 21 function_deprecation([:validate_hash, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Hash. There is further documentation for validate_legacy function in the README.'])22 23 21 unless args.length > 0 then 24 22 raise Puppet::ParseError, ("validate_hash(): wrong number of arguments (#{args.length}; must be > 0)") -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_integer.rb
rad28f83 rbcf0be5 3 3 newfunction(:validate_integer, :doc => <<-'ENDHEREDOC') do |args| 4 4 Validate that the first argument is an integer (or an array of integers). Abort catalog compilation if any of the checks fail. 5 5 6 6 The second argument is optional and passes a maximum. (All elements of) the first argument has to be less or equal to this max. 7 7 … … 53 53 54 54 ENDHEREDOC 55 56 function_deprecation([:validate_integer, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Integer. There is further documentation for validate_legacy function in the README.'])57 55 58 56 # tell the user we need at least one, and optionally up to two other parameters -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_ip_address.rb
rad28f83 rbcf0be5 9 9 validate_ip_address($my_ip) 10 10 validate_ip_address("8.8.8.8", "172.16.0.1", $my_ip) 11 11 12 12 $my_ip = "3ffe:505:2" 13 13 validate_ip_address(1) 14 14 validate_ip_address($my_ip) 15 15 validate_ip_address("fe80::baf6:b1ff:fe19:7507", $my_ip) 16 16 17 17 The following values will fail, causing compilation to abort: 18 18 $some_array = [ 1, true, false, "garbage string", "3ffe:505:2" ] … … 23 23 require "ipaddr" 24 24 rescuable_exceptions = [ ArgumentError ] 25 26 function_deprecation([:validate_ip_address, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Ip_address. There is further documentation for validate_legacy function in the README.'])27 25 28 26 if defined?(IPAddr::InvalidAddressError) -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_ipv4_address.rb
rad28f83 rbcf0be5 18 18 ENDHEREDOC 19 19 ) do |args| 20 21 function_deprecation([:validate_ipv4_address, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Ipv4. There is further documentation for validate_legacy function in the README.'])22 20 23 21 require "ipaddr" -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_ipv6_address.rb
rad28f83 rbcf0be5 19 19 ENDHEREDOC 20 20 ) do |args| 21 22 function_deprecation([:validate_ipv6_address, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Ipv6. There is further documentation for validate_legacy function in the README.'])23 21 24 22 require "ipaddr" -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_numeric.rb
rad28f83 rbcf0be5 3 3 newfunction(:validate_numeric, :doc => <<-'ENDHEREDOC') do |args| 4 4 Validate that the first argument is a numeric value (or an array of numeric values). Abort catalog compilation if any of the checks fail. 5 5 6 6 The second argument is optional and passes a maximum. (All elements of) the first argument has to be less or equal to this max. 7 7 … … 15 15 16 16 ENDHEREDOC 17 18 function_deprecation([:validate_numeric, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Numeric. There is further documentation for validate_legacy function in the README.'])19 17 20 18 # tell the user we need at least one, and optionally up to two other parameters -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_re.rb
rad28f83 rbcf0be5 30 30 31 31 ENDHEREDOC 32 33 function_deprecation([:validate_re, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Re. There is further documentation for validate_legacy function in the README.'])34 35 32 if (args.length < 2) or (args.length > 3) then 36 33 raise Puppet::ParseError, "validate_re(): wrong number of arguments (#{args.length}; must be 2 or 3)" -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_slength.rb
rad28f83 rbcf0be5 21 21 22 22 ENDHEREDOC 23 24 function_deprecation([:validate_slength, 'This method is deprecated, please use the stdlib validate_legacy function, with String[]. There is further documentation for validate_legacy function in the README.'])25 23 26 24 raise Puppet::ParseError, "validate_slength(): Wrong number of arguments (#{args.length}; must be 2 or 3)" unless args.length == 2 or args.length == 3 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/validate_string.rb
rad28f83 rbcf0be5 14 14 validate_string(true) 15 15 validate_string([ 'some', 'array' ]) 16 16 17 17 Note: validate_string(undef) will not fail in this version of the 18 18 functions API (incl. current and future parser). Instead, use: 19 19 20 20 if $var == undef { 21 21 fail('...') 22 22 } 23 23 24 24 ENDHEREDOC 25 26 function_deprecation([:validate_string, 'This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::String. There is further documentation for validate_legacy function in the README.'])27 25 28 26 unless args.length > 0 then … … 31 29 32 30 args.each do |arg| 33 # when called through the v4 API shim, undef gets translated to nil 34 unless arg.is_a?(String) || arg.nil? 31 unless arg.is_a?(String) 35 32 raise Puppet::ParseError, ("#{arg.inspect} is not a string. It looks to be a #{arg.class}") 36 33 end -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/values.rb
rad28f83 rbcf0be5 22 22 ) do |arguments| 23 23 24 raise(Puppet::ParseError, "values(): Wrong number of arguments given (#{arguments.size} for 1)") if arguments.size < 1 24 raise(Puppet::ParseError, "values(): Wrong number of arguments " + 25 "given (#{arguments.size} for 1)") if arguments.size < 1 25 26 26 27 hash = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/values_at.rb
rad28f83 rbcf0be5 30 30 ) do |arguments| 31 31 32 raise(Puppet::ParseError, "values_at(): Wrong number of arguments given (#{arguments.size} for 2)") if arguments.size < 2 32 raise(Puppet::ParseError, "values_at(): Wrong number of " + 33 "arguments given (#{arguments.size} for 2)") if arguments.size < 2 33 34 34 35 array = arguments.shift … … 41 42 42 43 if not indices or indices.empty? 43 raise(Puppet::ParseError, 'values_at(): You must provide at least one positive index to collect') 44 raise(Puppet::ParseError, 'values_at(): You must provide ' + 45 'at least one positive index to collect') 44 46 end 45 47 … … 56 58 57 59 if start > stop 58 raise(Puppet::ParseError, 'values_at(): Stop index in given indices range is smaller than the start index') 60 raise(Puppet::ParseError, 'values_at(): Stop index in ' + 61 'given indices range is smaller than the start index') 59 62 elsif stop > array.size - 1 # First element is at index 0 is it not? 60 raise(Puppet::ParseError, 'values_at(): Stop index in given indices range exceeds array size') 63 raise(Puppet::ParseError, 'values_at(): Stop index in ' + 64 'given indices range exceeds array size') 61 65 end 62 66 … … 70 74 # Only positive numbers allowed in this case ... 71 75 if not i.match(/^\d+$/) 72 raise(Puppet::ParseError, 'values_at(): Unknown format of given index') 76 raise(Puppet::ParseError, 'values_at(): Unknown format ' + 77 'of given index') 73 78 end 74 79 … … 77 82 78 83 if i > array.size - 1 # Same story. First element is at index 0 ... 79 raise(Puppet::ParseError, 'values_at(): Given index exceeds array size') 84 raise(Puppet::ParseError, 'values_at(): Given index ' + 85 'exceeds array size') 80 86 end 81 87 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/parser/functions/zip.rb
rad28f83 rbcf0be5 18 18 19 19 # Technically we support three arguments but only first is mandatory ... 20 raise(Puppet::ParseError, "zip(): Wrong number of arguments given (#{arguments.size} for 2)") if arguments.size < 2 20 raise(Puppet::ParseError, "zip(): Wrong number of arguments " + 21 "given (#{arguments.size} for 2)") if arguments.size < 2 21 22 22 23 a = arguments[0] -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/provider/file_line/ruby.rb
rad28f83 rbcf0be5 5 5 else 6 6 lines.find do |line| 7 if resource[:ensure].to_s == 'absent' and resource[:match_for_absence].to_s == 'true' 8 line.chomp =~ Regexp.new(resource[:match]) 9 else 10 line.chomp == resource[:line].chomp 11 end 7 line.chomp == resource[:line].chomp 12 8 end 13 9 end … … 41 37 # small-ish config files that can fit into memory without 42 38 # too much trouble. 43 begin 44 @lines ||= File.readlines(resource[:path], :encoding => resource[:encoding]) 45 rescue TypeError => e 46 # Ruby 1.8 doesn't support open_args 47 @lines ||= File.readlines(resource[:path]) 48 end 39 @lines ||= File.readlines(resource[:path]) 49 40 end 50 41 -
src/puppetcode/environments/gnuboat/modules/stdlib/lib/puppet/type/file_line.rb
rad28f83 rbcf0be5 49 49 error will be raised unless the `multiple => true` parameter is set. 50 50 51 Encoding example:52 53 file_line { "XScreenSaver":54 ensure => present,55 path => '/root/XScreenSaver'56 line => "*lock: 10:00:00",57 match => '^*lock:',58 encoding => "iso-8859-1",59 }60 61 Files with special characters that are not valid UTF-8 will give the62 error message "invalid byte sequence in UTF-8". In this case, determine63 the correct file encoding and specify the correct encoding using the64 encoding attribute, the value of which needs to be a valid Ruby character65 encoding.66 67 51 **Autorequires:** If Puppet is managing the file that will contain the line 68 52 being managed, the file_line resource will autorequire that file. … … 88 72 desc 'An optional value to determine if match should be applied when ensure => absent.' + 89 73 ' If set to true and match is set, the line that matches match will be deleted.' + 90 ' If set to false (the default), match is ignored when ensure => absent.' + 91 ' When `ensure => present`, match_for_absence is ignored.' 74 ' If set to false (the default), match is ignored when ensure => absent.' 92 75 newvalues(true, false) 93 76 defaultto false … … 101 84 102 85 newparam(:after) do 103 desc 'An optional value used to specify the line after which we will add any new lines. (Existing lines are added in place)' + 104 ' This is also takes a regex.' 86 desc 'An optional value used to specify the line after which we will add any new lines. (Existing lines are added in place)' 105 87 end 106 88 … … 112 94 desc 'The file Puppet will ensure contains the line specified by the line parameter.' 113 95 validate do |value| 114 unless Puppet::Util.absolute_path?(value)115 raise Puppet::Error, "File paths must be fully qualified, not '#{value}'"96 unless (Puppet.features.posix? and value =~ /^\//) or (Puppet.features.microsoft_windows? and (value =~ /^.:\// or value =~ /^\/\/[^\/]+\/[^\/]+/)) 97 raise(Puppet::Error, "File paths must be fully qualified, not '#{value}'") 116 98 end 117 99 end … … 122 104 newvalues(true, false) 123 105 defaultto true 124 end125 126 newparam(:encoding) do127 desc 'For files that are not UTF-8 encoded, specify encoding such as iso-8859-1'128 defaultto 'UTF-8'129 106 end 130 107 -
src/puppetcode/environments/gnuboat/modules/stdlib/metadata.json
rad28f83 rbcf0be5 1 1 { 2 2 "name": "puppetlabs-stdlib", 3 "version": "4.1 7.1",3 "version": "4.12.0", 4 4 "author": "puppetlabs", 5 5 "summary": "Standard library of resources for Puppet modules.", … … 70 70 "10.04", 71 71 "12.04", 72 "14.04", 73 "16.04" 72 "14.04" 74 73 ] 75 74 }, … … 78 77 "operatingsystemrelease": [ 79 78 "10", 80 "11" 79 "11", 80 "12" 81 81 ] 82 82 }, … … 105 105 "requirements": [ 106 106 { 107 "name": "pe", 108 "version_requirement": ">= 3.0.0 < 2015.4.0" 109 }, 110 { 107 111 "name": "puppet", 108 "version_requirement": ">= 4.7.0 <5.0.0"112 "version_requirement": ">=2.7.20 <5.0.0" 109 113 } 110 114 ], -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/abs_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'abs function' do4 describe 'abs function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should accept a string' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/anchor_spec.rb
rad28f83 rbcf0be5 1 1 require 'spec_helper_acceptance' 2 2 3 describe 'anchor type' do3 describe 'anchor type', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 4 4 describe 'success' do 5 5 it 'should effect proper chaining of resources' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/any2array_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'any2array function' do4 describe 'any2array function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should create an empty array' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/base64_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'base64 function' do4 describe 'base64 function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should encode then decode a string' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/bool2num_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'bool2num function' do4 describe 'bool2num function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 ['false', 'f', '0', 'n', 'no'].each do |bool| -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/capitalize_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'capitalize function' do4 describe 'capitalize function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should capitalize the first letter of a string' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/ceiling_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'ceiling function' do4 describe 'ceiling function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'ceilings floats' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/chomp_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'chomp function' do4 describe 'chomp function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should eat the newline' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/chop_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'chop function' do4 describe 'chop function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should eat the last character' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/clamp_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'clamp function' do4 describe 'clamp function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'clamps list of values' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/concat_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'concat function' do4 describe 'concat function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should concat one array to another' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/count_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'count function' do4 describe 'count function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should count elements in an array' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/deep_merge_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'deep_merge function' do4 describe 'deep_merge function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should deep merge two hashes' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/defined_with_params_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'defined_with_params function' do4 describe 'defined_with_params function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should successfully notify' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/delete_at_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'delete_at function' do4 describe 'delete_at function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should delete elements of the array' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/delete_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'delete function' do4 describe 'delete function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should delete elements of the array' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/delete_undef_values_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'delete_undef_values function' do4 describe 'delete_undef_values function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should delete elements of the array' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/delete_values_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'delete_values function' do4 describe 'delete_values function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should delete elements of the hash' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/difference_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'difference function' do4 describe 'difference function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'returns non-duplicates in the first array' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/dirname_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'dirname function' do4 describe 'dirname function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 context 'absolute path' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/downcase_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'downcase function' do4 describe 'downcase function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'returns the downcase' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/empty_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'empty function' do4 describe 'empty function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'recognizes empty strings' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/flatten_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'flatten function' do4 describe 'flatten function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'flattens arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/floor_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'floor function' do4 describe 'floor function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'floors floats' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/fqdn_rand_string_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'fqdn_rand_string function' do4 describe 'fqdn_rand_string function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 include_context "with faked facts" -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/fqdn_rotate_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'fqdn_rotate function' do4 describe 'fqdn_rotate function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 include_context "with faked facts" -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/get_module_path_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'get_module_path function' do4 describe 'get_module_path function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'get_module_paths dne' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/getparam_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'getparam function' do4 describe 'getparam function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'getparam a notify' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/getvar_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'getvar function' do4 describe 'getvar function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'getvars from classes' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/grep_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'grep function' do4 describe 'grep function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'greps arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/has_interface_with_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'has_interface_with function', :unless => (( fact('osfamily') == 'windows') or (fact('osfamily') == 'AIX')) do4 describe 'has_interface_with function', :unless => ((UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem'))) or (fact('osfamily') == 'windows') or (fact('osfamily') == 'AIX')) do 5 5 describe 'success' do 6 6 it 'has_interface_with existing ipaddress' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/has_ip_address_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'has_ip_address function', :unless => (( fact('osfamily') == 'windows') or (fact('osfamily') == 'AIX')) do4 describe 'has_ip_address function', :unless => ((UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem'))) or (fact('osfamily') == 'windows') or (fact('osfamily') == 'AIX')) do 5 5 describe 'success' do 6 6 it 'has_ip_address existing ipaddress' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/has_ip_network_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'has_ip_network function', :unless => (( fact('osfamily') == 'windows') or (fact('osfamily') == 'AIX')) do4 describe 'has_ip_network function', :unless => ((UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem'))) or (fact('osfamily') == 'windows') or (fact('osfamily') == 'AIX')) do 5 5 describe 'success' do 6 6 it 'has_ip_network existing ipaddress' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/has_key_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'has_key function' do4 describe 'has_key function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'has_keys in hashes' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/hash_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'hash function' do4 describe 'hash function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'hashs arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/intersection_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'intersection function' do4 describe 'intersection function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'intersections arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_a_spec.rb
rad28f83 rbcf0be5 3 3 4 4 if get_puppet_version =~ /^4/ 5 describe 'is_a function' do5 describe 'is_a function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 6 6 it 'should match a string' do 7 7 pp = <<-EOS -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_array_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_array function' do4 describe 'is_array function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_arrays arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_bool_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_bool function' do4 describe 'is_bool function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_bools arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_domain_name_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_domain_name function' do4 describe 'is_domain_name function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_domain_names arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_float_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_float function' do4 describe 'is_float function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_floats arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_function_available_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_function_available function' do4 describe 'is_function_available function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_function_availables arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_hash_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_hash function' do4 describe 'is_hash function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_hashs arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_integer_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_integer function' do4 describe 'is_integer function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_integers arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_ip_address_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_ip_address function' do4 describe 'is_ip_address function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_ip_addresss ipv4' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_ipv4_address_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_ipv4_address function' do4 describe 'is_ipv4_address function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_ipv4_addresss' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_ipv6_address_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_ipv6_address function' do4 describe 'is_ipv6_address function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_ipv6_addresss' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_mac_address_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_mac_address function' do4 describe 'is_mac_address function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_mac_addresss a mac' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_numeric_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_numeric function' do4 describe 'is_numeric function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_numerics arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/is_string_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'is_string function' do4 describe 'is_string function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'is_strings arrays' do … … 96 96 end 97 97 end 98 it 'is_strings undef' do99 pp = <<-EOS100 $a = undef101 $o = is_string($a)102 notice(inline_template('is_string is <%= @o.inspect %>'))103 EOS104 105 apply_manifest(pp, :catch_failures => true) do |r|106 expect(r.stdout).to match(/is_string is true/)107 end108 end109 98 end 110 99 describe 'failure' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/join_keys_to_values_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'join_keys_to_values function' do4 describe 'join_keys_to_values function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'join_keys_to_valuess hashes' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/join_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'join function' do4 describe 'join function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'joins arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/keys_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'keys function' do4 describe 'keys function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'keyss hashes' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/loadyaml_spec.rb
rad28f83 rbcf0be5 4 4 tmpdir = default.tmpdir('stdlib') 5 5 6 describe 'loadyaml function' do6 describe 'loadyaml function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 7 7 describe 'success' do 8 8 it 'loadyamls array of values' do … … 27 27 end 28 28 end 29 30 it 'returns the default value if there is no file to load' do31 pp = <<-EOS32 $o = loadyaml('#{tmpdir}/no-file.yaml', {'default' => 'value'})33 notice(inline_template('loadyaml[default] is <%= @o["default"].inspect %>'))34 EOS35 36 apply_manifest(pp, :catch_failures => true) do |r|37 expect(r.stdout).to match(/loadyaml\[default\] is "value"/)38 end39 end40 41 it 'returns the default value if the file was parsed with an error' do42 shell("echo '!' > #{tmpdir}/testyaml.yaml")43 pp = <<-EOS44 $o = loadyaml('#{tmpdir}/testyaml.yaml', {'default' => 'value'})45 notice(inline_template('loadyaml[default] is <%= @o["default"].inspect %>'))46 EOS47 48 apply_manifest(pp, :catch_failures => true) do |r|49 expect(r.stdout).to match(/loadyaml\[default\] is "value"/)50 end51 end52 29 end 53 30 describe 'failure' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/lstrip_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'lstrip function' do4 describe 'lstrip function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'lstrips arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/max_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'max function' do4 describe 'max function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'maxs arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/member_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'member function' do4 describe 'member function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 shared_examples 'item found' do 6 6 it 'should output correctly' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/merge_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'merge function' do4 describe 'merge function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'should merge two hashes' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/min_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'min function' do4 describe 'min function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'mins arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/nodesets/default.yml
rad28f83 rbcf0be5 1 1 HOSTS: 2 ubuntu-1404-x64:2 centos-65-x64: 3 3 roles: 4 - agent5 - default6 platform: ubuntu-14.04-amd647 hypervisor: vagrant8 box: puppetlabs/ubuntu-14.04-64-nocm4 - master 5 platform: el-6-x86_64 6 box : centos-65-x64-vbox436-nocm 7 box_url : http://puppet-vagrant-boxes.puppetlabs.com/centos-65-x64-virtualbox-nocm.box 8 hypervisor : vagrant 9 9 CONFIG: 10 10 type: foss -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/num2bool_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'num2bool function' do4 describe 'num2bool function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'bools positive numbers and numeric strings as true' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/parsejson_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'parsejson function' do4 describe 'parsejson function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'parses valid json' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/parseyaml_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'parseyaml function' do4 describe 'parseyaml function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'parses valid yaml' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/pick_default_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'pick_default function' do4 describe 'pick_default function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'pick_defaults a default value' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/pick_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'pick function' do4 describe 'pick function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'picks a default value' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/prefix_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'prefix function' do4 describe 'prefix function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'prefixes array of values' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/pw_hash_spec.rb
rad28f83 rbcf0be5 3 3 4 4 # Windows and OS X do not have useful implementations of crypt(3) 5 describe 'pw_hash function', :unless => ( ['windows', 'Darwin', 'SLES']).include?(fact('operatingsystem')) do5 describe 'pw_hash function', :unless => (UNSUPPORTED_PLATFORMS + ['windows', 'Darwin', 'SLES']).include?(fact('operatingsystem')) do 6 6 describe 'success' do 7 7 it 'hashes passwords' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/range_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'range function' do4 describe 'range function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'ranges letters' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/reject_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'reject function' do4 describe 'reject function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'rejects array of values' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/reverse_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'reverse function' do4 describe 'reverse function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'reverses strings' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/rstrip_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'rstrip function' do4 describe 'rstrip function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'rstrips arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/shuffle_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'shuffle function' do4 describe 'shuffle function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'shuffles arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/size_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'size function' do4 describe 'size function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'single string size' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/sort_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'sort function' do4 describe 'sort function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'sorts arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/squeeze_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'squeeze function' do4 describe 'squeeze function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'squeezes arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/str2bool_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'str2bool function' do4 describe 'str2bool function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'works with "y"' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/str2saltedsha512_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'str2saltedsha512 function' do4 describe 'str2saltedsha512 function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'works with "y"' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/strftime_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'strftime function' do4 describe 'strftime function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'gives the Century' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/strip_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'strip function' do4 describe 'strip function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'strips arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/suffix_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'suffix function' do4 describe 'suffix function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'suffixes array of values' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/swapcase_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'swapcase function' do4 describe 'swapcase function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'works with strings' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/time_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'time function' do4 describe 'time function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'gives the time' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/to_bytes_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'to_bytes function' do4 describe 'to_bytes function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'converts kB to B' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/try_get_value_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'try_get_value function' do4 describe 'try_get_value function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'gets a value' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/type_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'type function' do4 describe 'type function', :unless => (UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) || is_future_parser_enabled?) do 5 5 describe 'success' do 6 6 it 'types arrays' do … … 9 9 # Anagram: Large picture halls, I bet 10 10 $o = type($a) 11 notice(inline_template('type is <%= @o. to_s%>'))11 notice(inline_template('type is <%= @o.inspect %>')) 12 12 EOS 13 13 14 14 apply_manifest(pp, :catch_failures => true) do |r| 15 expect(r.stdout).to match(/type is Tuple\[String.*, String.*, String.*, String.*\]/)15 expect(r.stdout).to match(/type is "array"/) 16 16 end 17 17 end … … 20 20 $a = "blowzy night-frumps vex'd jack q" 21 21 $o = type($a) 22 notice(inline_template('type is <%= @o. to_s%>'))22 notice(inline_template('type is <%= @o.inspect %>')) 23 23 EOS 24 24 25 25 apply_manifest(pp, :catch_failures => true) do |r| 26 expect(r.stdout).to match(/type is String/)26 expect(r.stdout).to match(/type is "string"/) 27 27 end 28 28 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/union_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'union function' do4 describe 'union function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'unions arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/unique_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'unique function' do4 describe 'unique function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'uniques arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/upcase_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'upcase function' do4 describe 'upcase function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'upcases arrays' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/uriescape_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'uriescape function' do4 describe 'uriescape function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'uriescape strings' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_absolute_path_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'validate_absolute_path function' do4 describe 'validate_absolute_path function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 %w{ -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_array_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'validate_array function' do4 describe 'validate_array function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'validates a single argument' do … … 21 21 apply_manifest(pp, :catch_failures => true) 22 22 end 23 [24 %{validate_array({'a' => 'hash' })},25 %{validate_array('string')},26 %{validate_array(false)},27 %{validate_array(undef)}28 ].each do |pp|29 it "rejects #{pp.inspect}" do30 expect(apply_manifest(pp, :expect_failures => true).stderr).to match(/ is not an Array\. It looks to be a/)23 it 'validates a non-array' do 24 { 25 %{validate_array({'a' => 'hash' })} => "Hash", 26 %{validate_array('string')} => "String", 27 %{validate_array(false)} => "FalseClass", 28 %{validate_array(undef)} => "String" 29 }.each do |pp,type| 30 expect(apply_manifest(pp, :expect_failures => true).stderr).to match(/a #{type}/) 31 31 end 32 32 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_augeas_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'validate_augeas function', :unless => ( fact('osfamily') == 'windows') do4 describe 'validate_augeas function', :unless => ((UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem'))) or (fact('osfamily') == 'windows')) do 5 5 describe 'prep' do 6 6 it 'installs augeas for tests' -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_bool_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'validate_bool function' do4 describe 'validate_bool function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'validates a single argument' do … … 21 21 apply_manifest(pp, :catch_failures => true) 22 22 end 23 [24 %{validate_bool('true')},25 %{validate_bool('false')},26 %{validate_bool([true])},27 %{validate_bool(undef)}28 ].each do |pp|29 it "rejects #{pp.inspect}" do30 expect(apply_manifest(pp, :expect_failures => true).stderr).to match(/ is not a boolean\. It looks to be a/)23 it 'validates a non-bool' do 24 { 25 %{validate_bool('true')} => "String", 26 %{validate_bool('false')} => "String", 27 %{validate_bool([true])} => "Array", 28 %{validate_bool(undef)} => "String", 29 }.each do |pp,type| 30 expect(apply_manifest(pp, :expect_failures => true).stderr).to match(/a #{type}/) 31 31 end 32 32 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_cmd_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'validate_cmd function' do4 describe 'validate_cmd function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'validates a true command' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_hash_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'validate_hash function' do4 describe 'validate_hash function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'validates a single argument' do … … 21 21 apply_manifest(pp, :catch_failures => true) 22 22 end 23 [24 %{validate_hash('{ "not" => "hash" }')},25 %{validate_hash('string')},26 %{validate_hash(["array"])},27 %{validate_hash(undef)}28 ].each do |pp|29 it "rejects #{pp.inspect}" do30 expect(apply_manifest(pp, :expect_failures => true).stderr).to match(/ /)23 it 'validates a non-hash' do 24 { 25 %{validate_hash('{ "not" => "hash" }')} => "String", 26 %{validate_hash('string')} => "String", 27 %{validate_hash(["array"])} => "Array", 28 %{validate_hash(undef)} => "String", 29 }.each do |pp,type| 30 expect(apply_manifest(pp, :expect_failures => true).stderr).to match(/a #{type}/) 31 31 end 32 32 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_ipv4_address_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'validate_ipv4_address function' do4 describe 'validate_ipv4_address function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'validates a single argument' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_ipv6_address_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'validate_ipv6_address function' do4 describe 'validate_ipv6_address function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'validates a single argument' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_re_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'validate_re function' do4 describe 'validate_re function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'validates a string' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_slength_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'validate_slength function' do4 describe 'validate_slength function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'validates a single string max' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/validate_string_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'validate_string function' do4 describe 'validate_string function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'validates a single argument' do … … 21 21 apply_manifest(pp, :catch_failures => true) 22 22 end 23 it 'validates undef' do24 pp = <<-EOS25 validate_string(undef)26 EOS27 28 apply_manifest(pp, :catch_failures => true)29 end30 23 it 'validates a non-string' do 31 24 { -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/values_at_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'values_at function' do4 describe 'values_at function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'returns a specific value' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/values_spec.rb
rad28f83 rbcf0be5 2 2 require 'spec_helper_acceptance' 3 3 4 describe 'values function' do4 describe 'values function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 5 describe 'success' do 6 6 it 'returns an array of values' do … … 14 14 notice(inline_template('<%= @output.sort.inspect %>')) 15 15 EOS 16 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[1, 2, 3\]/) 16 if is_future_parser_enabled? 17 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[1, 2, 3\]/) 18 else 19 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\["1", "2", "3"\]/) 20 end 21 17 22 end 18 23 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/acceptance/zip_spec.rb
rad28f83 rbcf0be5 1 1 #! /usr/bin/env ruby -S rspec 2 2 require 'spec_helper_acceptance' 3 require 'puppet' 3 4 4 describe 'zip function' do5 describe 'zip function', :unless => UNSUPPORTED_PLATFORMS.include?(fact('operatingsystem')) do 5 6 describe 'success' do 6 7 it 'zips two arrays of numbers together' do … … 11 12 notice(inline_template('<%= @output.inspect %>')) 12 13 EOS 13 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[\[1, 5\], \[2, 6\], \[3, 7\], \[4, 8\]\]/) 14 if is_future_parser_enabled? 15 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[\[1, 5\], \[2, 6\], \[3, 7\], \[4, 8\]\]/) 16 else 17 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[\["1", "5"\], \["2", "6"\], \["3", "7"\], \["4", "8"\]\]/) 18 end 14 19 end 15 20 it 'zips two arrays of numbers & bools together' do … … 20 25 notice(inline_template('<%= @output.inspect %>')) 21 26 EOS 22 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[\[1, true\], \[2, true\], \["three", false\], \[4, false\]\]/) 27 if is_future_parser_enabled? 28 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[\[1, true\], \[2, true\], \["three", false\], \[4, false\]\]/) 29 else 30 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[\["1", true\], \["2", true\], \["three", false\], \["4", false\]\]/) 31 end 23 32 end 24 33 it 'zips two arrays of numbers together and flattens them' do … … 33 42 notice(inline_template('<%= @output.inspect %>')) 34 43 EOS 35 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[1, 5, 2, 6, 3, 7, 4, 8\]/) 44 if is_future_parser_enabled? 45 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[1, 5, 2, 6, 3, 7, 4, 8\]/) 46 else 47 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\["1", "5", "2", "6", "3", "7", "4", "8"\]/) 48 end 36 49 end 37 50 it 'handles unmatched length' do … … 43 56 notice(inline_template('<%= @output.inspect %>')) 44 57 EOS 45 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[\[1, 5\], \[2, 6\]\]/) 58 if is_future_parser_enabled? 59 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[\[1, 5\], \[2, 6\]\]/) 60 else 61 expect(apply_manifest(pp, :catch_failures => true).stdout).to match(/\[\["1", "5"\], \["2", "6"\]\]/) 62 end 46 63 end 47 64 end … … 53 70 notice(inline_template('<%= @output.inspect %>')) 54 71 EOS 72 55 73 expect(apply_manifest(pp, :expect_failures => true).stderr).to match(/Wrong number of arguments/) 56 74 end … … 62 80 notice(inline_template('<%= @output.inspect %>')) 63 81 EOS 82 64 83 expect(apply_manifest(pp, :expect_failures => true).stderr).to match(/Requires array/) 65 84 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/any2array_spec.rb
rad28f83 rbcf0be5 13 13 it { is_expected.to run.with_params({ 'key' => 'value' }).and_return(['key', 'value']) } 14 14 it { is_expected.to run.with_params({ 'key' => 'value' }).and_return(['key', 'value']) } 15 16 it { is_expected.to run.with_params('‰').and_return(['‰']) }17 it { is_expected.to run.with_params('竹').and_return(['竹']) }18 it { is_expected.to run.with_params('Ü').and_return(['Ü']) }19 it { is_expected.to run.with_params('∇').and_return(['∇']) }20 it { is_expected.to run.with_params('€', '万', 'Ö', '♥', '割').and_return(['€', '万', 'Ö', '♥', '割']) }21 15 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/assert_private_spec.rb
rad28f83 rbcf0be5 6 6 scope.expects(:lookupvar).with('module_name').returns('foo') 7 7 scope.expects(:lookupvar).with('caller_module_name').returns('foo') 8 expect { 9 subject.call [] 10 }.not_to raise_error 11 end 12 end 8 13 9 is_expected.to run.with_params() 14 context "with an explicit failure message" do 15 it "prints the failure message on error" do 16 scope.expects(:lookupvar).with('module_name').returns('foo') 17 scope.expects(:lookupvar).with('caller_module_name').returns('bar') 18 expect { 19 subject.call ['failure message!'] 20 }.to raise_error Puppet::ParseError, /failure message!/ 10 21 end 11 22 end 12 23 13 24 context "when called from private class" do 14 before :eachdo25 it "should fail with a class error message" do 15 26 scope.expects(:lookupvar).with('module_name').returns('foo') 16 27 scope.expects(:lookupvar).with('caller_module_name').returns('bar') 17 end18 19 it "should fail with a class error message" do20 28 scope.source.expects(:name).returns('foo::baz') 21 29 scope.source.expects(:type).returns('hostclass') 22 23 is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /Class foo::baz is private/) 24 end 25 26 context "with an explicit failure message" do 27 it { is_expected.to run.with_params('failure message!').and_raise_error(Puppet::ParseError, /failure message!/) } 30 expect { 31 subject.call [] 32 }.to raise_error Puppet::ParseError, /Class foo::baz is private/ 28 33 end 29 34 end … … 35 40 scope.source.expects(:name).returns('foo::baz') 36 41 scope.source.expects(:type).returns('definition') 37 38 is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /Definition foo::baz is private/) 42 expect { 43 subject.call [] 44 }.to raise_error Puppet::ParseError, /Definition foo::baz is private/ 39 45 end 40 46 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/basename_spec.rb
rad28f83 rbcf0be5 12 12 it { is_expected.to run.with_params('relative_path/to/a/file.ext', '.ext').and_return('file') } 13 13 it { is_expected.to run.with_params('scheme:///path/to/a/file.ext').and_return('file.ext') } 14 15 context 'should run with UTF8 and double byte characters' do16 it { is_expected.to run.with_params('scheme:///√ạĺűē/竹.ext').and_return('竹.ext') }17 it { is_expected.to run.with_params('ҝẽγ:/√ạĺűē/竹.ㄘ', '.ㄘ').and_return('竹') }18 end19 14 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/chomp_spec.rb
rad28f83 rbcf0be5 18 18 it { is_expected.to run.with_params(AlsoString.new("one\n\n")).and_return("one\n") } 19 19 it { is_expected.to run.with_params([AlsoString.new("one\n"), AlsoString.new("two"), "three\n"]).and_return(["one", "two", "three"]) } 20 21 context 'should run with UTF8 and double byte characters' do22 it { is_expected.to run.with_params("ůťƒ8\n\n").and_return("ůťƒ8\n") }23 it { is_expected.to run.with_params("ネット\n\n").and_return("ネット\n") }24 end25 20 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/chop_spec.rb
rad28f83 rbcf0be5 18 18 it { is_expected.to run.with_params(AlsoString.new("one\n\n")).and_return("one\n") } 19 19 it { is_expected.to run.with_params([AlsoString.new("one\n"), AlsoString.new("two"), "three\n"]).and_return(["one", "tw", "three"]) } 20 21 context 'should run with UTF8 and double byte characters' do22 it { is_expected.to run.with_params("ůťƒ8\n\n").and_return("ůťƒ8\n") }23 it { is_expected.to run.with_params("ネット\n\n").and_return("ネット\n") }24 end25 20 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/concat_spec.rb
rad28f83 rbcf0be5 12 12 it { is_expected.to run.with_params(['1','2'],['3','4'],['5','6']).and_return(['1','2','3','4','5','6']) } 13 13 it { is_expected.to run.with_params(['1','2'],'3','4',['5','6']).and_return(['1','2','3','4','5','6']) } 14 15 context 'should run with UTF8 and double byte characters' do16 14 it { is_expected.to run.with_params([{"a" => "b"}], {"c" => "d", "e" => "f"}).and_return([{"a" => "b"}, {"c" => "d", "e" => "f"}]) } 17 it { is_expected.to run.with_params(['ấ','β','©'],['đ','ể','文字列']).and_return(['ấ','β','©','đ','ể','文字列']) }18 end19 15 20 16 it "should leave the original array intact" do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/count_spec.rb
rad28f83 rbcf0be5 16 16 it { is_expected.to run.with_params(["one", "", "two"]).and_return(2) } 17 17 it { is_expected.to run.with_params(["one", :undef, "two"]).and_return(2) } 18 19 it { is_expected.to run.with_params(["ổņ℮", "ŧщộ", "three"]).and_return(3) }20 it { is_expected.to run.with_params(["ổņ℮", "ŧщộ", "ŧщộ"], "ŧщộ").and_return(2) }21 it { is_expected.to run.with_params(["ổņ℮", nil, "ŧщộ"]).and_return(2) }22 it { is_expected.to run.with_params(["ổņ℮", :undef, "ŧщộ"]).and_return(2) }23 18 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/deep_merge_spec.rb
rad28f83 rbcf0be5 53 53 expect(argument2).to eq(original2) 54 54 end 55 56 context 'should run with UTF8 and double byte characters' do57 it { is_expected.to run.with_params({'ĸέỹ1' => 'ϋǻļủë1'}, {'この文字列' => '万' }).and_return({'ĸέỹ1' => 'ϋǻļủë1', 'この文字列' => '万'}) }58 end59 55 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/defined_with_params_spec.rb
rad28f83 rbcf0be5 12 12 it { is_expected.to run.with_params('User[bob]', {}).and_return(false) } 13 13 it { is_expected.to run.with_params('User[dan]', {'foo' => 'bar'}).and_return(false) } 14 15 context 'should run with UTF8 and double byte characters' do16 it { is_expected.to run.with_params('User[ĵĭмოү]', {}).and_return(false) }17 it { is_expected.to run.with_params('User[ポーラ]', {}).and_return(false) }18 end19 14 end 20 15 … … 29 24 it { is_expected.to run.with_params('User[dan]', {'ensure' => 'absent', 'managehome' => false}).and_return(false) } 30 25 end 31 32 describe 'when passing undef values' do33 let :pre_condition do34 'file { "/tmp/a": ensure => present }'35 end36 37 it { is_expected.to run.with_params('File[/tmp/a]', {}).and_return(true) }38 it { is_expected.to run.with_params('File[/tmp/a]', { 'ensure' => 'present', 'owner' => :undef }).and_return(true) }39 end40 41 describe 'when the reference is a' do42 let :pre_condition do43 'user { "dan": }'44 end45 context 'reference' do46 it { is_expected.to run.with_params(Puppet::Resource.new('User[dan]'), {}).and_return(true) }47 end48 if Puppet::Util::Package.versioncmp(Puppet.version, '4.6.0') >= 049 context 'array' do50 it 'fails' do51 expect {52 subject.call([['User[dan]'], {}])53 }.to raise_error ArgumentError, /not understood: 'Array'/54 end55 end56 end57 end58 59 describe 'when passed a defined type' do60 let :pre_condition do61 'test::deftype { "foo": }'62 end63 it { is_expected.to run.with_params('Test::Deftype[foo]', {}).and_return(true) }64 it { is_expected.to run.with_params('Test::Deftype[bar]', {}).and_return(false) }65 it { is_expected.to run.with_params(Puppet::Resource.new('Test::Deftype[foo]'), {}).and_return(true) }66 it { is_expected.to run.with_params(Puppet::Resource.new('Test::Deftype[bar]'), {}).and_return(false) }67 end68 26 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/delete_at_spec.rb
rad28f83 rbcf0be5 19 19 it { is_expected.to run.with_params([0, 1, 2], -1).and_return([0, 1]) } 20 20 it { is_expected.to run.with_params([0, 1, 2], -4).and_return([0, 1, 2]) } 21 it { is_expected.to run.with_params(["ƒờở", "βāř", "ьầż"], 1).and_return(["ƒờở", "ьầż"]) }22 23 21 24 22 it "should leave the original array intact" do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/delete_spec.rb
rad28f83 rbcf0be5 5 5 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError) } 6 6 it { is_expected.to run.with_params([]).and_raise_error(Puppet::ParseError) } 7 it { is_expected.to run.with_params([], 'two') }8 7 it { is_expected.to run.with_params([], 'two', 'three').and_raise_error(Puppet::ParseError) } 9 8 it { is_expected.to run.with_params(1, 'two').and_raise_error(TypeError) } … … 14 13 it { is_expected.to run.with_params(['two'], 'two').and_return([]) } 15 14 it { is_expected.to run.with_params(['two', 'two'], 'two').and_return([]) } 16 it { is_expected.to run.with_params(['ab', 'b', 'c', 'b'], 'b').and_return(['ab', 'c']) }17 15 it { is_expected.to run.with_params(['one', 'two', 'three'], 'four').and_return(['one', 'two', 'three']) } 18 16 it { is_expected.to run.with_params(['one', 'two', 'three'], 'e').and_return(['one', 'two', 'three']) } … … 20 18 it { is_expected.to run.with_params(['two', 'one', 'two', 'three', 'two'], 'two').and_return(['one', 'three']) } 21 19 it { is_expected.to run.with_params(['one', 'two', 'three', 'two'], ['one', 'two']).and_return(['three']) } 22 it { is_expected.to run.with_params(['ồאּẻ', 'ŧẅơ', 'ŧңŗё℮', 'ŧẅơ'], ['ồאּẻ', 'ŧẅơ']).and_return(['ŧңŗё℮']) }23 20 end 24 21 … … 32 29 it { is_expected.to run.with_params('foobarbabarz', 'bar').and_return('foobaz') } 33 30 it { is_expected.to run.with_params('foobarbabarz', ['foo', 'bar']).and_return('baz') } 34 it { is_expected.to run.with_params('ƒōōβậяβậβậяź', ['ƒōō', 'βậя']).and_return('βậź') } 35 31 # this is so sick 36 32 it { is_expected.to run.with_params('barfoobar', ['barbar', 'foo']).and_return('barbar') } 37 33 it { is_expected.to run.with_params('barfoobar', ['foo', 'barbar']).and_return('') } … … 49 45 .with_params({'key1' => 'value1', 'key2' => 'value2', 'key3' => 'value3'}, ['key1', 'key2']) \ 50 46 .and_return( {'key3' => 'value3'}) 51 }52 it { is_expected.to run \53 .with_params({'ĸəұ1' => 'νãŀủĕ1', 'ĸəұ2' => 'νãŀủĕ2', 'ĸəұ3' => 'νãŀủĕ3'}, ['ĸəұ1', 'ĸəұ2']) \54 .and_return( {'ĸəұ3' => 'νãŀủĕ3'})55 47 } 56 48 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/delete_undef_values_spec.rb
rad28f83 rbcf0be5 17 17 it { is_expected.to run.with_params([undef_value]).and_return([]) } 18 18 it { is_expected.to run.with_params(['one',undef_value,'two','three']).and_return(['one','two','three']) } 19 it { is_expected.to run.with_params(['ớņέ',undef_value,'ŧשּׁō','ŧħґëə']).and_return(['ớņέ','ŧשּׁō','ŧħґëə']) }20 19 end 21 20 -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/delete_values_spec.rb
rad28f83 rbcf0be5 20 20 } 21 21 it { is_expected.to run \ 22 .with_params({'ҝếỵ1 ' => 'νâĺūẹ1', 'ҝếỵ2' => 'value to delete'}, 'value to delete') \ 23 .and_return({'ҝếỵ1 ' => 'νâĺūẹ1'}) 24 } 25 it { is_expected.to run \ 26 .with_params({'key1' => 'value1', 'key2' => 'νǎŀữ℮ ťớ đêłểťė'}, 'νǎŀữ℮ ťớ đêłểťė') \ 22 .with_params({'key1' => 'value1', 'key2' => 'value to delete'}, 'value to delete') \ 27 23 .and_return({'key1' => 'value1'}) 28 24 } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/difference_spec.rb
rad28f83 rbcf0be5 13 13 it { is_expected.to run.with_params([], ['one']).and_return([]) } 14 14 it { is_expected.to run.with_params(['one'], ['one']).and_return([]) } 15 it { is_expected.to run.with_params(['ớņέ'], ['']).and_return(['ớņέ']) }16 15 it { is_expected.to run.with_params(['one'], []).and_return(['one']) } 17 16 it { is_expected.to run.with_params(['one', 'two', 'three'], ['two', 'three']).and_return(['one']) } 18 it { is_expected.to run.with_params(['ớņέ', 'ŧשּׁō', 'ŧħґëə', 2], ['ŧשּׁō', 'ŧħґëə']).and_return(['ớņέ', 2]) }19 17 it { is_expected.to run.with_params(['one', 'two', 'two', 'three'], ['two', 'three']).and_return(['one']) } 20 18 it { is_expected.to run.with_params(['one', 'two', 'three'], ['two', 'two', 'three']).and_return(['one']) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/dig_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'dig' do 4 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError) } 5 it { is_expected.to run.with_params('bad', []).and_raise_error(Puppet::ParseError) } 6 it { is_expected.to run.with_params({}, 'bad').and_raise_error(Puppet::ParseError) } 4 7 5 it "should exist" do 6 expect(Puppet::Parser::Functions.function("dig")).to eq("function_dig") 7 end 8 9 it "should give a deprecation warning when called" do 10 scope.expects(:warning).with("dig() DEPRECATED: This function has been replaced in Puppet 4.5.0, please use dig44() for backwards compatibility or use the new version.") 11 scope.function_dig([{}, []]) 12 end 8 it { is_expected.to run.with_params({}, []).and_return({}) } 9 it { is_expected.to run.with_params({"a" => "b"}, ["a"]).and_return("b") } 10 it { is_expected.to run.with_params({"a" => {"b" => "c"}}, ["a", "b"]).and_return("c") } 11 it { is_expected.to run.with_params({}, ["a", "b"], "d").and_return("d") } 12 it { is_expected.to run.with_params({"a" => false}, ["a"]).and_return(false) } 13 13 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/dirname_spec.rb
rad28f83 rbcf0be5 11 11 it { is_expected.to run.with_params('/path/to/a/file.ext').and_return('/path/to/a') } 12 12 it { is_expected.to run.with_params('relative_path/to/a/file.ext').and_return('relative_path/to/a') } 13 14 context 'should run with UTF8 and double byte characters' do15 it { is_expected.to run.with_params('scheme:///√ạĺűē/竹.ext').and_return('scheme:///√ạĺűē') }16 it { is_expected.to run.with_params('ҝẽγ:/√ạĺűē/竹.ㄘ').and_return('ҝẽγ:/√ạĺűē') }17 end18 13 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/dos2unix_spec.rb
rad28f83 rbcf0be5 30 30 end 31 31 32 context ' Internationalization (i18N) values' do33 sample_text _utf8 = "Ħ℮ļłǿ\r\nשׁөŕłđ\r\n"34 desired_output _utf8 = "Ħ℮ļłǿ\nשׁөŕłđ\n"32 context 'Converting from unix to unix format' do 33 sample_text = "Hello\nWorld\n" 34 desired_output = "Hello\nWorld\n" 35 35 36 sample_text_doublebyte = "こんにちは\r\n世界\r\n" 37 desired_output_doublebyte = "こんにちは\n世界\n" 38 39 it 'should output uft8 string' do 40 should run.with_params(sample_text_utf8).and_return(desired_output_utf8) 41 end 42 43 it 'should output double byte string' do 44 should run.with_params(sample_text_doublebyte).and_return(desired_output_doublebyte) 36 it 'should output unix format' do 37 should run.with_params(sample_text).and_return(desired_output) 45 38 end 46 39 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/ensure_packages_spec.rb
rad28f83 rbcf0be5 34 34 end 35 35 end 36 37 context 'given an empty packages array' do38 let(:pre_condition) { 'notify { "hi": } -> Package <| |>; $somearray = ["vim",""]; ensure_packages($somearray)' }39 40 describe 'after running ensure_package(["vim", ""])' do41 it { expect { catalogue }.to raise_error(Puppet::ParseError, /Empty String provided/) }42 end43 end44 45 context 'given hash of packages' do46 before { subject.call([{"foo" => { "provider" => "rpm" }, "bar" => { "provider" => "gem" }}, { "ensure" => "present"}]) }47 before { subject.call([{"パッケージ" => { "ensure" => "absent"}}]) }48 before { subject.call([{"ρǻ¢κầģẻ" => { "ensure" => "absent"}}]) }49 50 # this lambda is required due to strangeness within rspec-puppet's expectation handling51 it { expect(lambda { catalogue }).to contain_package('foo').with({'provider' => 'rpm', 'ensure' => 'present'}) }52 it { expect(lambda { catalogue }).to contain_package('bar').with({'provider' => 'gem', 'ensure' => 'present'}) }53 54 context 'should run with UTF8 and double byte characters' do55 it { expect(lambda { catalogue }).to contain_package('パッケージ').with({'ensure' => 'absent'}) }56 it { expect(lambda { catalogue }).to contain_package('ρǻ¢κầģẻ').with({'ensure' => 'absent'}) }57 end58 end59 36 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/ensure_resource_spec.rb
rad28f83 rbcf0be5 5 5 it { is_expected.to run.with_params().and_raise_error(ArgumentError, /Must specify a type/) } 6 6 it { is_expected.to run.with_params('type').and_raise_error(ArgumentError, /Must specify a title/) } 7 if Puppet::Util::Package.versioncmp(Puppet.version, '4.6.0') >= 0 8 it { is_expected.to run.with_params('type', 'title', {}, 'extras').and_raise_error(ArgumentError) } 9 else 10 it { is_expected.to run.with_params('type', 'title', {}, 'extras').and_raise_error(Puppet::ParseError) } 11 end 12 7 it { is_expected.to run.with_params('type', 'title', {}, 'extras').and_raise_error(Puppet::ParseError) } 13 8 it { 14 9 pending("should not accept numbers as arguments") 15 10 is_expected.to run.with_params(1,2,3).and_raise_error(Puppet::ParseError) 16 11 } 17 18 context 'given an empty catalog' do19 describe 'after running ensure_resource("user", "username1", {})' do20 before { subject.call(['User', 'username1', {}]) }21 22 # this lambda is required due to strangeness within rspec-puppet's expectation handling23 it { expect(lambda { catalogue }).to contain_user('username1').without_ensure }24 end25 26 describe 'after running ensure_resource("user", "username1", { gid => undef })' do27 before { subject.call(['User', 'username1', { 'gid' => :undef }]) }28 29 # this lambda is required due to strangeness within rspec-puppet's expectation handling30 it { expect(lambda { catalogue }).to contain_user('username1').without_ensure }31 it { expect(lambda { catalogue }).to contain_user('username1').without_gid }32 end33 34 describe 'after running ensure_resource("user", "username1", { ensure => present, gid => undef })' do35 before { subject.call(['User', 'username1', { 'ensure' => 'present', 'gid' => :undef }]) }36 37 # this lambda is required due to strangeness within rspec-puppet's expectation handling38 it { expect(lambda { catalogue }).to contain_user('username1').with_ensure('present') }39 it { expect(lambda { catalogue }).to contain_user('username1').without_gid }40 end41 42 describe 'after running ensure_resource("test::deftype", "foo", {})' do43 before { subject.call(['test::deftype', 'foo', {}]) }44 45 # this lambda is required due to strangeness within rspec-puppet's expectation handling46 it { expect(lambda { catalogue }).to contain_test__deftype('foo').without_ensure }47 end48 end49 50 context 'given a catalog with UTF8 chars' do51 describe 'after running ensure_resource("user", "Şắოрŀễ Ţëם", {})' do52 before { subject.call(['User', 'Şắოрŀễ Ţëם', {}]) }53 54 # this lambda is required due to strangeness within rspec-puppet's expectation handling55 it { expect(lambda { catalogue }).to contain_user('Şắოрŀễ Ţëם').without_ensure }56 end57 58 describe 'after running ensure_resource("user", "Şắოрŀễ Ţëם", { gid => undef })' do59 before { subject.call(['User', 'Şắოрŀễ Ţëם', { 'gid' => :undef }]) }60 61 # this lambda is required due to strangeness within rspec-puppet's expectation handling62 it { expect(lambda { catalogue }).to contain_user('Şắოрŀễ Ţëם').without_ensure }63 it { expect(lambda { catalogue }).to contain_user('Şắოрŀễ Ţëם').without_gid }64 end65 66 describe 'after running ensure_resource("user", "Şắოрŀễ Ţëם", { ensure => present, gid => undef })' do67 before { subject.call(['User', 'Şắოрŀễ Ţëם', { 'ensure' => 'present', 'gid' => :undef }]) }68 69 # this lambda is required due to strangeness within rspec-puppet's expectation handling70 it { expect(lambda { catalogue }).to contain_user('Şắოрŀễ Ţëם').with_ensure('present') }71 it { expect(lambda { catalogue }).to contain_user('Şắოрŀễ Ţëם').without_gid }72 end73 end74 12 75 13 context 'given a catalog with "user { username1: ensure => present }"' do … … 89 27 it { expect(lambda { catalogue }).to contain_user('username1').with_ensure('present') } 90 28 it { expect(lambda { catalogue }).to contain_user('username2').without_ensure } 91 end92 93 describe 'after running ensure_resource("user", "username1", { gid => undef })' do94 before { subject.call(['User', 'username1', { 'gid' => :undef }]) }95 96 # this lambda is required due to strangeness within rspec-puppet's expectation handling97 it { expect(lambda { catalogue }).to contain_user('username1').with_ensure('present') }98 29 end 99 30 … … 122 53 end 123 54 end 124 125 context 'given a catalog with "test::deftype { foo: }"' do126 let(:pre_condition) { 'test::deftype { "foo": }' }127 128 describe 'after running ensure_resource("test::deftype", "foo", {})' do129 before { subject.call(['test::deftype', 'foo', {}]) }130 131 # this lambda is required due to strangeness within rspec-puppet's expectation handling132 it { expect(lambda { catalogue }).to contain_test__deftype('foo').without_ensure }133 end134 end135 55 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/flatten_spec.rb
rad28f83 rbcf0be5 12 12 it { is_expected.to run.with_params(["a","b","c","d","e","f","g"]).and_return(["a","b","c","d","e","f","g"]) } 13 13 it { is_expected.to run.with_params([["a","b",["c",["d","e"],"f","g"]]]).and_return(["a","b","c","d","e","f","g"]) } 14 it { is_expected.to run.with_params(["ã","β",["ĉ",["đ","ẽ","ƒ","ġ"]]]).and_return(["ã","β","ĉ","đ","ẽ","ƒ","ġ"]) }15 14 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/fqdn_rand_string_spec.rb
rad28f83 rbcf0be5 21 21 it { is_expected.to run.with_params(100, 'a').and_return(/\Aa{100}\z/) } 22 22 it { is_expected.to run.with_params(100, 'ab').and_return(/\A[ab]{100}\z/) } 23 it { is_expected.to run.with_params(100, 'ãβ').and_return(/\A[ãβ]{100}\z/) }24 23 25 24 it "provides the same 'random' value on subsequent calls for the same host" do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/fqdn_rotate_spec.rb
rad28f83 rbcf0be5 8 8 it { is_expected.to run.with_params('').and_return('') } 9 9 it { is_expected.to run.with_params('a').and_return('a') } 10 it { is_expected.to run.with_params('ã').and_return('ã') }11 10 12 11 it { is_expected.to run.with_params([]).and_return([]) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/getparam_spec.rb
rad28f83 rbcf0be5 23 23 it { is_expected.to run.with_params('User[two]', 'ensure').and_return('') } 24 24 it { is_expected.to run.with_params('User[one]', 'shell').and_return('/bin/sh') } 25 it { is_expected.to run.with_params('User[one]', 'managehome').and_return(false) } 26 end 27 28 describe 'when compared against a user resource with UTF8 and double byte params' do 29 let(:pre_condition) { 'user { ["三", "ƒốưř"]: ensure => present }' } 30 31 it { is_expected.to run.with_params('User[三]', 'ensure').and_return('present') } 32 it { is_expected.to run.with_params('User[ƒốưř]', 'ensure').and_return('present') } 33 25 it { 26 pending("both rspec-puppet as well as the function do the wrong thing here.") 27 is_expected.to run.with_params('User[one]', 'managehome').and_return(false) 28 } 34 29 end 35 30 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/getvar_spec.rb
rad28f83 rbcf0be5 6 6 it { is_expected.to run.with_params('one', 'two').and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } 7 7 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } 8 9 it { is_expected.to run.with_params('$::foo').and_return(nil) }10 8 11 9 context 'given variables in namespaces' do … … 21 19 it { is_expected.to run.with_params('::site::data::bar').and_return(nil) } 22 20 end 23 24 context 'given variables in namespaces' do25 let(:pre_condition) {26 <<-'ENDofPUPPETcode'27 class site::info { $lock = 'ŧҺîš íš ắ śţřĭŋĝ' }28 class site::new { $item = '万Ü€‰' }29 include site::info30 include site::new31 ENDofPUPPETcode32 }33 34 it { is_expected.to run.with_params('site::info::lock').and_return('ŧҺîš íš ắ śţřĭŋĝ') }35 it { is_expected.to run.with_params('::site::new::item').and_return('万Ü€‰') }36 end37 21 end 38 -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/grep_spec.rb
rad28f83 rbcf0be5 17 17 it { is_expected.to run.with_params(['one', 'two', 'three'], 'two').and_return(['two']) } 18 18 it { is_expected.to run.with_params(['one', 'two', 'three'], 't(wo|hree)').and_return(['two', 'three']) } 19 it { is_expected.to run.with_params(['ờאּê', 'ţשּׂỡ', 'ţһŗəè'], 'ţ(שּׂỡ|һŗəè)').and_return(['ţשּׂỡ', 'ţһŗəè']) }20 19 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/has_ip_network_spec.rb
rad28f83 rbcf0be5 10 10 { 11 11 :interfaces => 'eth0,lo', 12 :network => :undefined, 12 13 :network_lo => '127.0.0.0', 13 14 :network_eth0 => '10.0.0.0', -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/has_key_spec.rb
rad28f83 rbcf0be5 13 13 it { is_expected.to run.with_params({}, "key").and_return(false) } 14 14 it { is_expected.to run.with_params({ 'key' => 'value'}, "not a key").and_return(false) } 15 16 context 'should run with UTF8 and double byte characters' do17 it { is_expected.to run.with_params({ 'κéỳ ' => '٧ậļųể' }, "κéỳ ").and_return(true) }18 it { is_expected.to run.with_params({ 'キー' => '٧ậļųể' }, "キー").and_return(true) }19 end20 15 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/hash_spec.rb
rad28f83 rbcf0be5 11 11 it { is_expected.to run.with_params([]).and_return({}) } 12 12 it { is_expected.to run.with_params(['key1', 'value1']).and_return({ 'key1' => 'value1' }) } 13 it { is_expected.to run.with_params(['κ℮ұ1', '√āĺűẻ1']).and_return({ 'κ℮ұ1' => '√āĺűẻ1' }) }14 13 it { is_expected.to run.with_params(['key1', 'value1', 'key2', 'value2']).and_return({ 'key1' => 'value1', 'key2' => 'value2' }) } 15 14 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/intersection_spec.rb
rad28f83 rbcf0be5 15 15 it { is_expected.to run.with_params(['one'], ['one']).and_return(['one']) } 16 16 it { is_expected.to run.with_params(['one', 'two', 'three'], ['two', 'three']).and_return(['two', 'three']) } 17 it { is_expected.to run.with_params(['ōŋể', 'ŧשợ', 'ţђŕẽё'], ['ŧשợ', 'ţђŕẽё']).and_return(['ŧשợ', 'ţђŕẽё']) }18 17 it { is_expected.to run.with_params(['one', 'two', 'two', 'three'], ['two', 'three']).and_return(['two', 'three']) } 19 18 it { is_expected.to run.with_params(['one', 'two', 'three'], ['two', 'two', 'three']).and_return(['two', 'three']) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_a_spec.rb
rad28f83 rbcf0be5 22 22 is_expected.to run.with_params(5, String).and_return(false) 23 23 end 24 25 it 'suceeds when comparing an UTF8 and double byte characters' do26 is_expected.to run.with_params('このテキスト', String).and_return(true)27 is_expected.to run.with_params('ŧћịś ŧêχŧ', String).and_return(true)28 end29 24 end 30 25 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_array_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'is_array' do 4 5 4 it { is_expected.not_to eq(nil) } 6 5 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } … … 18 17 it { is_expected.to run.with_params(1).and_return(false) } 19 18 it { is_expected.to run.with_params({}).and_return(false) } 20 context 'Checking for deprecation warning' do21 after(:all) do22 ENV.delete('STDLIB_LOG_DEPRECATIONS')23 end24 # Checking for deprecation warning, which should only be provoked when the env variable for it is set.25 it 'should display a single deprecation' do26 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"27 scope.expects(:warning).with(includes('This method is deprecated'))28 is_expected.to run.with_params(['1.2.3.4']).and_return(true)29 end30 it 'should display no warning for deprecation' do31 ENV['STDLIB_LOG_DEPRECATIONS'] = "false"32 scope.expects(:warning).with(includes('This method is deprecated')).never33 is_expected.to run.with_params(['1.2.3.4']).and_return(true)34 end35 end36 19 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_bool_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'is_bool' do 4 5 4 it { is_expected.not_to eq(nil) } 6 5 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } … … 14 13 it { is_expected.to run.with_params('true').and_return(false) } 15 14 it { is_expected.to run.with_params('false').and_return(false) } 16 context 'Checking for deprecation warning' do17 after(:all) do18 ENV.delete('STDLIB_LOG_DEPRECATIONS')19 end20 # Checking for deprecation warning, which should only be provoked when the env variable for it is set.21 it 'should display a single deprecation' do22 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"23 scope.expects(:warning).with(includes('This method is deprecated'))24 is_expected.to run.with_params(true).and_return(true)25 end26 it 'should display no warning for deprecation' do27 ENV['STDLIB_LOG_DEPRECATIONS'] = "false"28 scope.expects(:warning).with(includes('This method is deprecated')).never29 is_expected.to run.with_params(false).and_return(true)30 end31 end32 15 end 33 -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_float_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'is_float' do 4 5 4 it { is_expected.not_to eq(nil) } 6 7 5 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } 8 6 it { is_expected.to run.with_params(0.1, 0.2).and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } … … 22 20 it { is_expected.to run.with_params(1).and_return(false) } 23 21 end 24 25 context 'Checking for deprecation warning' do26 after(:all) do27 ENV.delete('STDLIB_LOG_DEPRECATIONS')28 end29 # Checking for deprecation warning, which should only be provoked when the env variable for it is set.30 it 'should display a single deprecation' do31 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"32 scope.expects(:warning).with(includes('This method is deprecated'))33 is_expected.to run.with_params(2.2).and_return(true)34 end35 it 'should display no warning for deprecation' do36 ENV['STDLIB_LOG_DEPRECATIONS'] = "false"37 scope.expects(:warning).with(includes('This method is deprecated')).never38 is_expected.to run.with_params(1.0).and_return(true)39 end40 end41 42 22 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_integer_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'is_integer' do 4 5 4 it { is_expected.not_to eq(nil) } 6 7 5 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } 8 6 it { is_expected.to run.with_params(1, 2).and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } … … 12 10 it { is_expected.to run.with_params(-3).and_return(true) } 13 11 it { is_expected.to run.with_params('-3').and_return(true) } 14 12 15 13 it { is_expected.to run.with_params(3.7).and_return(false) } 16 14 it { is_expected.to run.with_params('3.7').and_return(false) } … … 25 23 it { is_expected.to run.with_params(false).and_return(false) } 26 24 it { is_expected.to run.with_params('0001234').and_return(false) } 27 28 context 'Checking for deprecation warning' do29 after(:all) do30 ENV.delete('STDLIB_LOG_DEPRECATIONS')31 end32 # Checking for deprecation warning, which should only be provoked when the env variable for it is set.33 it 'should display a single deprecation' do34 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"35 scope.expects(:warning).with(includes('This method is deprecated'))36 is_expected.to run.with_params(50).and_return(true)37 end38 it 'should display no warning for deprecation' do39 ENV['STDLIB_LOG_DEPRECATIONS'] = "false"40 scope.expects(:warning).with(includes('This method is deprecated')).never41 is_expected.to run.with_params(50).and_return(true)42 end43 end44 45 25 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_ip_address_spec.rb
rad28f83 rbcf0be5 21 21 it { is_expected.to run.with_params({}).and_return(false) } 22 22 it { is_expected.to run.with_params([]).and_return(false) } 23 24 context 'Checking for deprecation warning', if: Puppet.version.to_f < 4.0 do25 # Checking for deprecation warning, which should only be provoked when the env variable for it is set.26 it 'should display a single deprecation' do27 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"28 scope.expects(:warning).with(includes('This method is deprecated'))29 is_expected.to run.with_params('1.2.3.4').and_return(true)30 end31 it 'should display no warning for deprecation' do32 ENV['STDLIB_LOG_DEPRECATIONS'] = "false"33 scope.expects(:warning).with(includes('This method is deprecated')).never34 is_expected.to run.with_params('1.2.3.4').and_return(true)35 end36 after(:all) do37 ENV.delete('STDLIB_LOG_DEPRECATIONS')38 end39 end40 23 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_mac_address_spec.rb
rad28f83 rbcf0be5 10 10 it { is_expected.to run.with_params('').and_return(false) } 11 11 it { is_expected.to run.with_params('one').and_return(false) } 12 13 context 'function can handle UTF8 and double byte characters' do14 it { is_expected.to run.with_params('ƒốưř').and_return(false) }15 it { is_expected.to run.with_params('三+').and_return(false) }16 end17 18 12 it { 19 13 pending "should properly typecheck its arguments" -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_numeric_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'is_numeric' do 4 5 4 it { is_expected.not_to eq(nil) } 6 7 5 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } 8 6 it { is_expected.to run.with_params(1, 2).and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } … … 28 26 it { is_expected.to run.with_params('0001234').and_return(false) } 29 27 it { is_expected.to run.with_params(' - 1234').and_return(false) } 30 31 context 'Checking for deprecation warning' do32 after(:all) do33 ENV.delete('STDLIB_LOG_DEPRECATIONS')34 end35 # Checking for deprecation warning, which should only be provoked when the env variable for it is set.36 it 'should display a single deprecation' do37 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"38 scope.expects(:warning).with(includes('This method is deprecated'))39 is_expected.to run.with_params(7).and_return(true)40 end41 it 'should display no warning for deprecation' do42 ENV['STDLIB_LOG_DEPRECATIONS'] = "false"43 scope.expects(:warning).with(includes('This method is deprecated')).never44 is_expected.to run.with_params(7).and_return(true)45 end46 end47 48 28 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/is_string_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'is_string' do 4 5 4 it { is_expected.not_to eq(nil) } 6 5 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } … … 27 26 it { is_expected.to run.with_params('one').and_return(true) } 28 27 it { is_expected.to run.with_params('0001234').and_return(true) } 29 30 context 'Checking for deprecation warning' do31 after(:all) do32 ENV.delete('STDLIB_LOG_DEPRECATIONS')33 end34 # Checking for deprecation warning, which should only be provoked when the env variable for it is set.35 it 'should display a single deprecation' do36 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"37 scope.expects(:warning).with(includes('This method is deprecated'))38 is_expected.to run.with_params('sponge').and_return(true)39 end40 it 'should display no warning for deprecation' do41 ENV['STDLIB_LOG_DEPRECATIONS'] = "false"42 scope.expects(:warning).with(includes('This method is deprecated')).never43 is_expected.to run.with_params('bob').and_return(true)44 end45 end46 47 28 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/join_keys_to_values_spec.rb
rad28f83 rbcf0be5 12 12 it { is_expected.to run.with_params({ 'key' => 'value' }, '').and_return(['keyvalue']) } 13 13 it { is_expected.to run.with_params({ 'key' => 'value' }, ':').and_return(['key:value']) } 14 15 context 'should run with UTF8 and double byte characters' do16 it { is_expected.to run.with_params({ 'ҝẽγ' => '√ạĺűē' }, ':').and_return(['ҝẽγ:√ạĺűē']) }17 it { is_expected.to run.with_params({ 'ҝẽγ' => '√ạĺűē' }, '万').and_return(['ҝẽγ万√ạĺűē']) }18 end19 20 14 it { is_expected.to run.with_params({ 'key' => nil }, ':').and_return(['key:']) } 21 15 it 'should run join_keys_to_values(<hash with multiple keys>, ":") and return the proper array' do … … 23 17 expect(result.sort).to eq(['key1:value1', 'key2:value2'].sort) 24 18 end 25 it 'should run join_keys_to_values(<hash with array value>, " ") and return the proper array' do26 result = subject.call([{ 'key1' => 'value1', 'key2' => ['value2', 'value3'] }, ' '])27 expect(result.sort).to eq(['key1 value1', 'key2 value2', 'key2 value3'].sort)28 end29 19 end 30 -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/join_spec.rb
rad28f83 rbcf0be5 17 17 it { is_expected.to run.with_params(['one', 'two', 'three']).and_return('onetwothree') } 18 18 it { is_expected.to run.with_params(['one', 'two', 'three'], ':').and_return('one:two:three') } 19 it { is_expected.to run.with_params(['ōŋể', 'ŧשợ', 'ţђŕẽё'], ':').and_return('ōŋể:ŧשợ:ţђŕẽё') }20 19 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/keys_spec.rb
rad28f83 rbcf0be5 17 17 expect(result).to match_array(['key1', 'key2']) 18 18 end 19 20 it 'should run with UTF8 and double byte characters' do21 result = subject.call([{ 'ҝểү' => '√ẳŀμệ', 'キー' => '値' }])22 expect(result).to match_array(['ҝểү', 'キー'])23 end24 19 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/load_module_metadata_spec.rb
rad28f83 rbcf0be5 6 6 it { is_expected.to run.with_params("one", "two", "three").and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } 7 7 8 describe "when calling with valid arguments" do 9 before :each do 10 allow(File).to receive(:read).with(/\/(stdlib|test)\/metadata.json/, {:encoding=>"utf-8"}).and_return('{"name": "puppetlabs-stdlib"}') 11 allow(File).to receive(:read).with(/\/(stdlib|test)\/metadata.json/).and_return('{"name": "puppetlabs-stdlib"}') 12 end 8 it "should json parse the file" do 9 allow(scope).to receive(:function_get_module_path).with(['science']).and_return('/path/to/module/') 10 allow(File).to receive(:exists?).with(/metadata.json/).and_return(true) 11 allow(File).to receive(:read).with(/metadata.json/).and_return('{"name": "spencer-science"}') 13 12 14 context "when calling with valid utf8 and double byte character arguments" do 15 before :each do 16 allow(File).to receive(:read).with(/\/(stdlib|test)\/metadata.json/, {:encoding=>"utf-8"}).and_return('{"ĭďèʼnţĩƒіểя": "ċơņťęאּť ỡƒ ţħíš - 17 この文字"}') 18 allow(File).to receive(:read).with(/\/(stdlib|test)\/metadata.json/).and_return('{"ĭďèʼnţĩƒіểя": "ċơņťęאּť ỡƒ ţħíš - 19 この文字"}') 20 end 13 result = subject.call(['science']) 14 expect(result['name']).to eq('spencer-science') 15 end 21 16 22 it "should json parse the file" do 23 if Puppet::Util::Platform.windows? 24 allow(scope).to receive(:function_get_module_path).with(['science']).and_return('C:/path/to/module/') 25 allow(File).to receive(:exists?).with('C:/path/to/module/metadata.json').and_return(true) 26 allow(File).to receive(:read).with('C:/path/to/module/metadata.json').and_return('{"name": "spencer-science"}') 27 else 28 allow(scope).to receive(:function_get_module_path).with(['science']).and_return('/path/to/module/') 29 allow(File).to receive(:exists?).with('/path/to/module/metadata.json').and_return(true) 30 allow(File).to receive(:read).with('/path/to/module/metadata.json').and_return('{"name": "spencer-science"}') 31 end 17 it "should fail by default if there is no metadata.json" do 18 allow(scope).to receive(:function_get_module_path).with(['science']).and_return('/path/to/module/') 19 allow(File).to receive(:exists?).with(/metadata.json/).and_return(false) 20 expect {subject.call(['science'])}.to raise_error(Puppet::ParseError) 21 end 32 22 33 result = subject.call(['science']) 34 expect(result['name']).to eq('spencer-science') 35 end 36 37 it "should fail by default if there is no metadata.json" do 38 if Puppet::Util::Platform.windows? 39 allow(scope).to receive(:function_get_module_path).with(['science']).and_return('C:/path/to/module/') 40 allow(File).to receive(:exists?).with('C:/path/to/module/metadata.json').and_return(false) 41 else 42 allow(scope).to receive(:function_get_module_path).with(['science']).and_return('/path/to/module/') 43 allow(File).to receive(:exists?).with('/path/to/module/metadata.json').and_return(false) 44 end 45 expect {subject.call(['science'])}.to raise_error(Puppet::ParseError) 46 end 47 48 it "should return nil if user allows empty metadata.json" do 49 if Puppet::Util::Platform.windows? 50 allow(scope).to receive(:function_get_module_path).with(['science']).and_return('C:/path/to/module/') 51 allow(File).to receive(:exists?).with('C:/path/to/module/metadata.json').and_return(false) 52 else 53 allow(scope).to receive(:function_get_module_path).with(['science']).and_return('/path/to/module/') 54 allow(File).to receive(:exists?).with('/path/to/module/metadata.json').and_return(false) 55 end 56 result = subject.call(['science', true]) 57 expect(result).to eq({}) 58 end 59 end 23 it "should return nil if user allows empty metadata.json" do 24 allow(scope).to receive(:function_get_module_path).with(['science']).and_return('/path/to/module/') 25 allow(File).to receive(:exists?).with(/metadata.json/).and_return(false) 26 result = subject.call(['science', true]) 27 expect(result).to eq({}) 60 28 end 61 29 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/loadyaml_spec.rb
rad28f83 rbcf0be5 3 3 describe 'loadyaml' do 4 4 it { is_expected.not_to eq(nil) } 5 it { is_expected.to run.with_params().and_raise_error( ArgumentError, /wrong number of arguments/i) }6 5 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } 6 it { is_expected.to run.with_params('', '').and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } 7 7 context 'when a non-existing file is specified' do 8 8 let(:filename) { '/tmp/doesnotexist' } … … 11 11 YAML.expects(:load_file).never 12 12 } 13 it { is_expected.to run.with_params(filename, {'default' => 'value'}).and_return({'default' => 'value'}) } 14 it { is_expected.to run.with_params(filename, {'đẽƒằưļŧ' => '٧ẵłựέ'}).and_return({'đẽƒằưļŧ' => '٧ẵłựέ'}) } 15 it { is_expected.to run.with_params(filename, {'デフォルト' => '値'}).and_return({'デフォルト' => '値'}) } 13 it { is_expected.to run.with_params(filename).and_return(nil) } 16 14 end 17 18 15 context 'when an existing file is specified' do 19 16 let(:filename) { '/tmp/doesexist' } 20 let(:data) { { 'key' => 'value' , 'ķęŷ' => 'νậŀųề', 'キー' => '値'} }17 let(:data) { { 'key' => 'value' } } 21 18 before { 22 19 File.expects(:exists?).with(filename).returns(true).once … … 25 22 it { is_expected.to run.with_params(filename).and_return(data) } 26 23 end 27 28 context 'when the file could not be parsed' do29 let(:filename) { '/tmp/doesexist' }30 before {31 File.expects(:exists?).with(filename).returns(true).once32 YAML.stubs(:load_file).with(filename).once.raises StandardError, 'Something terrible have happened!'33 }34 it { is_expected.to run.with_params(filename, {'default' => 'value'}).and_return({'default' => 'value'}) }35 end36 24 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/lstrip_spec.rb
rad28f83 rbcf0be5 23 23 it { is_expected.to run.with_params(' one ').and_return('one ') } 24 24 it { is_expected.to run.with_params(' one ').and_return('one ') } 25 it { is_expected.to run.with_params(' ǿňè ').and_return('ǿňè ') }26 25 it { is_expected.to run.with_params("\tone ").and_return('one ') } 27 26 it { is_expected.to run.with_params("\t one ").and_return('one ') } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/member_spec.rb
rad28f83 rbcf0be5 18 18 it { is_expected.to run.with_params(['one'], ['one']).and_return(true) } 19 19 it { is_expected.to run.with_params(['one', 'two', 'three', 'four'], ['four', 'two']).and_return(true) } 20 it { is_expected.to run.with_params(['ọאּẹ', 'ŧẅồ', 'ţҺŗęē', 'ƒơџŕ'], ['ƒơџŕ', 'ŧẅồ']).and_return(true) }21 20 it { is_expected.to run.with_params(['one', 'two', 'three', 'four'], ['four', 'five']).and_return(false) } 22 it { is_expected.to run.with_params(['ọאּẹ', 'ŧẅồ', 'ţҺŗęē', 'ƒơџŕ'], ['ƒơџŕ', 'ƒί√ə']).and_return(false) }23 21 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/parsejson_spec.rb
rad28f83 rbcf0be5 13 13 context 'with correct JSON data' do 14 14 15 it 'should be able to parse JSON data with a Hash' do15 it 'should be able to parse a JSON data with a Hash' do 16 16 is_expected.to run.with_params('{"a":"1","b":"2"}'). 17 17 and_return({'a'=>'1', 'b'=>'2'}) 18 18 end 19 19 20 it 'should be able to parse JSON data with an Array' do20 it 'should be able to parse a JSON data with an Array' do 21 21 is_expected.to run.with_params('["a","b","c"]'). 22 22 and_return(['a', 'b', 'c']) … … 30 30 end 31 31 32 it 'should be able to parse JSON data with a mixed structure' do32 it 'should be able to parse a JSON data with a mixed structure' do 33 33 is_expected.to run.with_params('{"a":"1","b":2,"c":{"d":[true,false]}}'). 34 34 and_return({'a' =>'1', 'b' => 2, 'c' => { 'd' => [true, false] } }) 35 end36 37 it 'should be able to parse JSON data with a UTF8 and double byte characters' do38 is_expected.to run.with_params('{"×":"これ","ý":"記号","です":{"©":["Á","ß"]}}').39 and_return({'×' =>'これ', 'ý' => '記号', 'です' => { '©' => ['Á', 'ß'] } })40 35 end 41 36 -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/parseyaml_spec.rb
rad28f83 rbcf0be5 19 19 end 20 20 21 it 'should be able to parse YAML data with a Hash' do21 it 'should be able to parse a YAML data with a Hash' do 22 22 is_expected.to run.with_params("---\na: '1'\nb: '2'\n"). 23 23 and_return({'a' => '1', 'b' => '2'}) 24 24 end 25 25 26 it 'should be able to parse YAML data with an Array' do26 it 'should be able to parse a YAML data with an Array' do 27 27 is_expected.to run.with_params("---\n- a\n- b\n- c\n"). 28 28 and_return(['a', 'b', 'c']) 29 29 end 30 30 31 it 'should be able to parse YAML data with a mixed structure' do31 it 'should be able to parse a YAML data with a mixed structure' do 32 32 is_expected.to run.with_params("---\na: '1'\nb: 2\nc:\n d:\n - :a\n - true\n - false\n"). 33 33 and_return({'a' => '1', 'b' => 2, 'c' => {'d' => [:a, true, false]}}) 34 end35 36 it 'should be able to parse YAML data with a UTF8 and double byte characters' do37 is_expected.to run.with_params("---\na: ×\nこれ: 記号\nです:\n ©:\n - Á\n - ß\n").38 and_return({"a"=>"×", "これ"=>"記号", "です"=>{"©"=>["Á", "ß"]} })39 34 end 40 35 -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/pick_default_spec.rb
rad28f83 rbcf0be5 6 6 7 7 it { is_expected.to run.with_params('one', 'two').and_return('one') } 8 it { is_expected.to run.with_params('ớņệ', 'ťωơ').and_return('ớņệ') }9 8 it { is_expected.to run.with_params('', 'two').and_return('two') } 10 9 it { is_expected.to run.with_params(:undef, 'two').and_return('two') } … … 15 14 describe "when providing #{value.inspect} as default" do 16 15 it { is_expected.to run.with_params('one', value).and_return('one') } 17 it { is_expected.to run.with_params('ớņệ', value).and_return('ớņệ') }18 16 it { is_expected.to run.with_params([], value).and_return([]) } 19 17 it { is_expected.to run.with_params({}, value).and_return({}) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/pick_spec.rb
rad28f83 rbcf0be5 10 10 it { is_expected.to run.with_params(:undefined, 'two').and_return('two') } 11 11 it { is_expected.to run.with_params(nil, 'two').and_return('two') } 12 13 context 'should run with UTF8 and double byte characters' do14 it { is_expected.to run.with_params(nil, 'このテキスト').and_return('このテキスト') }15 it { is_expected.to run.with_params('', 'ŝẳмрłề џţƒ8 ţẽם', 'このテキスト').and_return('ŝẳмрłề џţƒ8 ţẽם') }16 end17 12 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/prefix_spec.rb
rad28f83 rbcf0be5 12 12 it { is_expected.to run.with_params([]).and_return([]) } 13 13 it { is_expected.to run.with_params(['one', 2]).and_return(['one', '2']) } 14 it { is_expected.to run.with_params(['ớņệ', 2]).and_return(['ớņệ', '2']) }15 14 it { is_expected.to run.with_params([], '').and_return([]) } 16 15 it { is_expected.to run.with_params([''], '').and_return(['']) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/range_spec.rb
rad28f83 rbcf0be5 80 80 end 81 81 82 context 'with prefixed numbers as utf8 strings as bounds' do83 it { is_expected.to run.with_params('ħөŝŧ01', 'ħөŝŧ04').and_return(['ħөŝŧ01', 'ħөŝŧ02', 'ħөŝŧ03', 'ħөŝŧ04']) }84 end85 86 context 'with prefixed numbers as double byte character strings as bounds' do87 it { is_expected.to run.with_params('ホスト01', 'ホスト04').and_return(['ホスト01', 'ホスト02', 'ホスト03', 'ホスト04']) }88 end89 90 82 context 'with dash-range syntax' do 91 83 it { is_expected.to run.with_params('4-1').and_return([]) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/reject_spec.rb
rad28f83 rbcf0be5 17 17 it { is_expected.to run.with_params(['one', 'two', 'three'], 'two').and_return(['one', 'three']) } 18 18 it { is_expected.to run.with_params(['one', 'two', 'three'], 't(wo|hree)').and_return(['one']) } 19 it { is_expected.to run.with_params(['όʼnệ', 'ţщồ', 'ţңяέέ'], 'ţ(щồ|ңяέέ)').and_return(['όʼnệ']) }20 19 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/reverse_spec.rb
rad28f83 rbcf0be5 16 16 it { is_expected.to run.with_params(['one', 'two', 'three']).and_return(['three', 'two', 'one']) } 17 17 it { is_expected.to run.with_params(['one', 'two', 'three', 'four']).and_return(['four', 'three', 'two', 'one']) } 18 it { is_expected.to run.with_params(['ổňë', 'ťŵọ', 'ŧңяəė', 'ƒŏůŗ']).and_return(['ƒŏůŗ', 'ŧңяəė', 'ťŵọ', 'ổňë']) }19 18 20 19 it { is_expected.to run.with_params('').and_return('') } … … 22 21 it { is_expected.to run.with_params('abc').and_return('cba') } 23 22 it { is_expected.to run.with_params('abcd').and_return('dcba') } 24 it { is_expected.to run.with_params('āβćđ').and_return('đćβā') }25 23 26 24 context 'when using a class extending String' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/rstrip_spec.rb
rad28f83 rbcf0be5 23 23 it { is_expected.to run.with_params(' one ').and_return(' one') } 24 24 it { is_expected.to run.with_params(' one ').and_return(' one') } 25 it { is_expected.to run.with_params(' ǿňè ').and_return(' ǿňè') }26 25 it { is_expected.to run.with_params("\tone ").and_return("\tone") } 27 26 it { is_expected.to run.with_params("\t one ").and_return("\t one") } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/seeded_rand_spec.rb
rad28f83 rbcf0be5 51 51 scope.function_seeded_rand([max, seed]) 52 52 end 53 54 context 'should run with UTF8 and double byte characters' do55 it { is_expected.to run.with_params(1000, 'ǿňè')}56 it { is_expected.to run.with_params(1000, '文字列')}57 end58 53 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/shuffle_spec.rb
rad28f83 rbcf0be5 27 27 it { is_expected.to run.with_params('abcd').and_return('dcba') } 28 28 29 context 'should run with UTF8 and double byte characters' do30 it { is_expected.to run.with_params('ůţƒ8 ŧέχŧ şŧґíńģ').and_return('ģńş ůχţέƒŧí8ґŧŧ ') }31 it { is_expected.to run.with_params('日本語の文字列').and_return('字本日語文列の') }32 end33 34 29 context 'when using a class extending String' do 35 30 it { is_expected.to run.with_params(AlsoString.new('asdfghjkl')).and_return('lkhdsfajg') } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/size_spec.rb
rad28f83 rbcf0be5 20 20 it { is_expected.to run.with_params({'1' => '2'}).and_return(1) } 21 21 it { is_expected.to run.with_params({'1' => '2', '4' => '4'}).and_return(2) } 22 it { is_expected.to run.with_params({'€' => '@', '竹' => 'ǿňè'}).and_return(2) }23 22 24 23 it { is_expected.to run.with_params('').and_return(0) } … … 26 25 it { is_expected.to run.with_params('abc').and_return(3) } 27 26 it { is_expected.to run.with_params('abcd').and_return(4) } 28 it { is_expected.to run.with_params('万').and_return(1) }29 it { is_expected.to run.with_params('āβćđ').and_return(4) }30 27 31 28 context 'when using a class extending String' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/squeeze_spec.rb
rad28f83 rbcf0be5 15 15 it { is_expected.to run.with_params('aaaaaaaaa', 'a').and_return('a') } 16 16 it { is_expected.to run.with_params('aaaaaaaaabbbbbbbbbbcccccccccc', 'b-c').and_return('aaaaaaaaabc') } 17 end18 19 context 'should run with UTF8 and double byte characters' do20 it { is_expected.to run.with_params('ậậậậậậậậậậậậậậậậậậậậ').and_return('ậ') }21 it { is_expected.to run.with_params('語語語語語語語', '語').and_return('語') }22 it { is_expected.to run.with_params('ậậậậậậậậậậậậậậậậậ語語語語©©©©©', '©').and_return('ậậậậậậậậậậậậậậậậậ語語語語©') }23 17 end 24 18 -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/strip_spec.rb
rad28f83 rbcf0be5 31 31 it { is_expected.to run.with_params("\t one \t").and_return('one') } 32 32 it { is_expected.to run.with_params(' o n e ').and_return('o n e') } 33 it { is_expected.to run.with_params(' ỏŋέ ').and_return('ỏŋέ') }34 33 it { is_expected.to run.with_params(AlsoString.new(' one ')).and_return('one') } 35 34 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/suffix_spec.rb
rad28f83 rbcf0be5 16 16 it { is_expected.to run.with_params(['one'], 'post').and_return(['onepost']) } 17 17 it { is_expected.to run.with_params(['one', 'two', 'three'], 'post').and_return(['onepost', 'twopost', 'threepost']) } 18 it { is_expected.to run.with_params(['ỗńέ', 'ťשׂǿ', 'ŧҺř℮ə'], 'рổŝţ').and_return(['ỗńέрổŝţ', 'ťשׂǿрổŝţ', 'ŧҺř℮əрổŝţ']) }19 20 18 it { 21 19 is_expected.to run.with_params({}).and_return({}) -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/union_spec.rb
rad28f83 rbcf0be5 21 21 it { is_expected.to run.with_params(['one', 'two'], ['two', 'three'], ['one', 'three']).and_return(['one', 'two', 'three']) } 22 22 it { is_expected.to run.with_params(['one', 'two'], ['three', 'four'], ['one', 'two', 'three'], ['four']).and_return(['one', 'two', 'three', 'four']) } 23 it { is_expected.to run.with_params(['ốńə', 'ţשׂợ'], ['ŧĥяếệ', 'ƒởųŗ'], ['ốńə', 'ţשׂợ', 'ŧĥяếệ'], ['ƒởųŗ']).and_return(['ốńə', 'ţשׂợ', 'ŧĥяếệ', 'ƒởųŗ']) }24 23 it 'should not confuse types' do is_expected.to run.with_params(['1', '2', '3'], [1, 2]).and_return(['1', '2', '3', 1, 2]) end 25 24 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/unique_spec.rb
rad28f83 rbcf0be5 18 18 it { is_expected.to run.with_params(['a']).and_return(['a']) } 19 19 it { is_expected.to run.with_params(['a', 'b', 'a']).and_return(['a', 'b']) } 20 it { is_expected.to run.with_params(['ã', 'ъ', 'ã']).and_return(['ã', 'ъ']) }21 20 end 22 21 … … 25 24 it { is_expected.to run.with_params('a').and_return('a') } 26 25 it { is_expected.to run.with_params('aaba').and_return('ab') } 27 it { is_expected.to run.with_params('ããъã').and_return('ãъ') }28 26 end 29 27 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_absolute_path_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'validate_absolute_path' do 4 after(:all) do5 ENV.delete('STDLIB_LOG_DEPRECATIONS')6 end7 8 # Checking for deprecation warning9 it 'should display a single deprecation' do10 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"11 scope.expects(:warning).with(includes('This method is deprecated'))12 is_expected.to run.with_params('c:/')13 end14 15 4 describe 'signature validation' do 16 5 it { is_expected.not_to eq(nil) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_array_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'validate_array' do 4 5 4 describe 'signature validation' do 6 after(:all) do7 ENV.delete('STDLIB_LOG_DEPRECATIONS')8 end9 5 it { is_expected.not_to eq(nil) } 10 # Checking for deprecation warning11 it 'should display a single deprecation' do12 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"13 scope.expects(:warning).with(includes('This method is deprecated'))14 is_expected.to run.with_params([])15 end16 6 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } 17 7 -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_bool_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'validate_bool' do 4 after(:all) do5 ENV.delete('STDLIB_LOG_DEPRECATIONS')6 end7 8 # Checking for deprecation warning9 it 'should display a single deprecation' do10 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"11 scope.expects(:warning).with(includes('This method is deprecated'))12 is_expected.to run.with_params(true)13 end14 15 4 describe 'signature validation' do 16 5 it { is_expected.not_to eq(nil) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_cmd_spec.rb
rad28f83 rbcf0be5 1 1 require 'spec_helper' 2 2 3 describe 'validate_cmd' , :unless => Puppet::Util::Platform.windows?do3 describe 'validate_cmd' do 4 4 let(:touch) { File.exists?('/usr/bin/touch') ? '/usr/bin/touch' : '/bin/touch' } 5 5 -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_hash_spec.rb
rad28f83 rbcf0be5 5 5 it { is_expected.not_to eq(nil) } 6 6 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } 7 8 describe 'check for deprecation warning' do9 after(:all) do10 ENV.delete('STDLIB_LOG_DEPRECATIONS')11 end12 # Checking for deprecation warning13 it 'should display a single deprecation' do14 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"15 scope.expects(:warning).with(includes('This method is deprecated'))16 is_expected.to run.with_params({'key' => 'value'})17 end18 end19 7 20 8 describe 'valid inputs' do -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_integer_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'validate_integer' do 4 after(:all) do5 ENV.delete('STDLIB_LOG_DEPRECATIONS')6 end7 8 # Checking for deprecation warning9 it 'should display a single deprecation' do10 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"11 scope.expects(:warning).with(includes('This method is deprecated'))12 is_expected.to run.with_params(3)13 end14 15 4 describe 'signature validation' do 16 5 it { is_expected.not_to eq(nil) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_ip_address_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'validate_ip_address' do 4 5 4 describe 'signature validation' do 6 5 it { is_expected.not_to eq(nil) } … … 21 20 it { is_expected.to run.with_params('::1/64') } 22 21 it { is_expected.to run.with_params('fe80::a00:27ff:fe94:44d6/64') } 23 24 context 'Checking for deprecation warning', if: Puppet.version.to_f < 4.0 do25 after(:all) do26 ENV.delete('STDLIB_LOG_DEPRECATIONS')27 end28 # Checking for deprecation warning, which should only be provoked when the env variable for it is set.29 it 'should display a single deprecation' do30 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"31 scope.expects(:warning).with(includes('This method is deprecated'))32 is_expected.to run.with_params('1.2.3.4')33 end34 it 'should display no warning for deprecation' do35 ENV['STDLIB_LOG_DEPRECATIONS'] = "false"36 scope.expects(:warning).with(includes('This method is deprecated')).never37 is_expected.to run.with_params('1.2.3.4')38 end39 end40 41 22 context 'with netmasks' do 42 23 it { is_expected.to run.with_params('8.8.8.8/0') } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_ipv4_address_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'validate_ipv4_address' do 4 5 4 describe 'signature validation' do 6 5 it { is_expected.not_to eq(nil) } 7 6 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } 8 end9 7 10 context 'Checking for deprecation warning', if: Puppet.version.to_f < 4.0 do 11 after(:all) do 12 ENV.delete('STDLIB_LOG_DEPRECATIONS') 8 describe 'valid inputs' do 9 it { is_expected.to run.with_params('0.0.0.0') } 10 it { is_expected.to run.with_params('8.8.8.8') } 11 it { is_expected.to run.with_params('127.0.0.1') } 12 it { is_expected.to run.with_params('10.10.10.10') } 13 it { is_expected.to run.with_params('194.232.104.150') } 14 it { is_expected.to run.with_params('244.24.24.24') } 15 it { is_expected.to run.with_params('255.255.255.255') } 16 it { is_expected.to run.with_params('1.2.3.4', '5.6.7.8') } 17 context 'with netmasks' do 18 it { is_expected.to run.with_params('8.8.8.8/0') } 19 it { is_expected.to run.with_params('8.8.8.8/16') } 20 it { is_expected.to run.with_params('8.8.8.8/32') } 21 it { is_expected.to run.with_params('8.8.8.8/255.255.0.0') } 22 end 13 23 end 14 # Checking for deprecation warning, which should only be provoked when the env variable for it is set.15 it 'should display a single deprecation' do16 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"17 scope.expects(:warning).with(includes('This method is deprecated'))18 is_expected.to run.with_params(SharedData::IPV4_PATTERNS.first)19 end20 it 'should display no warning for deprecation' do21 ENV['STDLIB_LOG_DEPRECATIONS'] = "false"22 scope.expects(:warning).with(includes('This method is deprecated')).never23 is_expected.to run.with_params(SharedData::IPV4_PATTERNS.first)24 end25 end26 24 27 SharedData::IPV4_PATTERNS.each do |value| 28 it { is_expected.to run.with_params(value) } 29 end 30 31 SharedData::IPV4_NEGATIVE_PATTERNS.each do |value| 32 it { is_expected.to run.with_params(value).and_raise_error(Puppet::ParseError, /is not a valid IPv4/) } 33 end 34 35 describe 'invalid inputs' do 36 [ {}, [], 1, true ].each do |invalid| 37 it { is_expected.to run.with_params(invalid).and_raise_error(Puppet::ParseError, /is not a string/) } 38 it { is_expected.to run.with_params(SharedData::IPV4_PATTERNS.first, invalid).and_raise_error(Puppet::ParseError, /is not a string/) } 25 describe 'invalid inputs' do 26 it { is_expected.to run.with_params({}).and_raise_error(Puppet::ParseError, /is not a string/) } 27 it { is_expected.to run.with_params(1).and_raise_error(Puppet::ParseError, /is not a string/) } 28 it { is_expected.to run.with_params(true).and_raise_error(Puppet::ParseError, /is not a string/) } 29 it { is_expected.to run.with_params('one').and_raise_error(Puppet::ParseError, /is not a valid IPv4/) } 30 it { is_expected.to run.with_params('0.0.0').and_raise_error(Puppet::ParseError, /is not a valid IPv4/) } 31 it { is_expected.to run.with_params('0.0.0.256').and_raise_error(Puppet::ParseError, /is not a valid IPv4/) } 32 it { is_expected.to run.with_params('0.0.0.0.0').and_raise_error(Puppet::ParseError, /is not a valid IPv4/) } 33 it { is_expected.to run.with_params('affe::beef').and_raise_error(Puppet::ParseError, /is not a valid IPv4/) } 34 it { is_expected.to run.with_params('1.2.3.4', {}).and_raise_error(Puppet::ParseError, /is not a string/) } 35 it { is_expected.to run.with_params('1.2.3.4', 1).and_raise_error(Puppet::ParseError, /is not a string/) } 36 it { is_expected.to run.with_params('1.2.3.4', true).and_raise_error(Puppet::ParseError, /is not a string/) } 37 it { is_expected.to run.with_params('1.2.3.4', 'one').and_raise_error(Puppet::ParseError, /is not a valid IPv4/) } 39 38 end 40 39 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_ipv6_address_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'validate_ipv6_address' do 4 5 4 describe 'signature validation' do 6 5 it { is_expected.not_to eq(nil) } 7 6 it { is_expected.to run.with_params().and_raise_error(Puppet::ParseError, /wrong number of arguments/i) } 8 end9 7 10 context 'Checking for deprecation warning', if: Puppet.version.to_f < 4.0 do 11 after(:all) do 12 ENV.delete('STDLIB_LOG_DEPRECATIONS') 8 describe 'valid inputs' do 9 it { is_expected.to run.with_params('3ffe:0505:0002::') } 10 it { is_expected.to run.with_params('3ffe:0505:0002::', '3ffe:0505:0002::2') } 11 it { is_expected.to run.with_params('::1/64') } 12 it { is_expected.to run.with_params('fe80::a00:27ff:fe94:44d6/64') } 13 13 end 14 # Checking for deprecation warning, which should only be provoked when the env variable for it is set.15 it 'should display a single deprecation' do16 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"17 scope.expects(:warning).with(includes('This method is deprecated'))18 is_expected.to run.with_params('3ffe:0505:0002::')19 end20 it 'should display no warning for deprecation' do21 ENV['STDLIB_LOG_DEPRECATIONS'] = "false"22 scope.expects(:warning).with(includes('This method is deprecated')).never23 is_expected.to run.with_params('3ffe:0505:0002::')24 end25 end26 14 27 describe 'valid inputs' do 28 it { is_expected.to run.with_params('3ffe:0505:0002::') } 29 it { is_expected.to run.with_params('3ffe:0505:0002::', '3ffe:0505:0002::2') } 30 it { is_expected.to run.with_params('::1/64') } 31 it { is_expected.to run.with_params('fe80::a00:27ff:fe94:44d6/64') } 32 it { is_expected.to run.with_params('fe80:0000:0000:0000:0204:61ff:fe9d:f156') } 33 it { is_expected.to run.with_params('fe80:0:0:0:204:61ff:fe9d:f156') } 34 it { is_expected.to run.with_params('fe80::204:61ff:fe9d:f156') } 35 it { is_expected.to run.with_params('fe80:0:0:0:0204:61ff:254.157.241.86') } 36 it { is_expected.to run.with_params('::1') } 37 it { is_expected.to run.with_params('fe80::') } 38 it { is_expected.to run.with_params('2001::') } 39 end 40 41 describe 'invalid inputs' do 42 it { is_expected.to run.with_params({}).and_raise_error(Puppet::ParseError, /is not a string/) } 43 it { is_expected.to run.with_params(true).and_raise_error(Puppet::ParseError, /is not a string/) } 44 it { is_expected.to run.with_params('one').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 45 it { is_expected.to run.with_params('0.0.0').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 46 it { is_expected.to run.with_params('0.0.0.256').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 47 it { is_expected.to run.with_params('0.0.0.0.0').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 48 it { is_expected.to run.with_params('::ffff:2.3.4').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 49 it { is_expected.to run.with_params('::ffff:257.1.2.3').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 50 it { is_expected.to run.with_params('::ffff:12345678901234567890.1.26').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 51 it { is_expected.to run.with_params('affe:beef').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 52 it { is_expected.to run.with_params('::1', {}).and_raise_error(Puppet::ParseError, /is not a string/) } 53 it { is_expected.to run.with_params('::1', true).and_raise_error(Puppet::ParseError, /is not a string/) } 54 it { is_expected.to run.with_params('::1', 'one').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 55 context 'unless running on ruby 1.8.7', :if => RUBY_VERSION != '1.8.7' do 56 it { is_expected.to run.with_params(1).and_raise_error(Puppet::ParseError, /is not a string/) } 57 it { is_expected.to run.with_params('::1', 1).and_raise_error(Puppet::ParseError, /is not a string/) } 15 describe 'invalid inputs' do 16 it { is_expected.to run.with_params({}).and_raise_error(Puppet::ParseError, /is not a string/) } 17 it { is_expected.to run.with_params(true).and_raise_error(Puppet::ParseError, /is not a string/) } 18 it { is_expected.to run.with_params('one').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 19 it { is_expected.to run.with_params('0.0.0').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 20 it { is_expected.to run.with_params('0.0.0.256').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 21 it { is_expected.to run.with_params('0.0.0.0.0').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 22 it { is_expected.to run.with_params('affe:beef').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 23 it { is_expected.to run.with_params('::1', {}).and_raise_error(Puppet::ParseError, /is not a string/) } 24 it { is_expected.to run.with_params('::1', true).and_raise_error(Puppet::ParseError, /is not a string/) } 25 it { is_expected.to run.with_params('::1', 'one').and_raise_error(Puppet::ParseError, /is not a valid IPv6/) } 26 context 'unless running on ruby 1.8.7', :if => RUBY_VERSION != '1.8.7' do 27 it { is_expected.to run.with_params(1).and_raise_error(Puppet::ParseError, /is not a string/) } 28 it { is_expected.to run.with_params('::1', 1).and_raise_error(Puppet::ParseError, /is not a string/) } 29 end 58 30 end 59 31 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_numeric_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'validate_numeric' do 4 after(:all) do5 ENV.delete('STDLIB_LOG_DEPRECATIONS')6 end7 8 # Checking for deprecation warning9 it 'should display a single deprecation' do10 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"11 scope.expects(:warning).with(includes('This method is deprecated'))12 is_expected.to run.with_params(3)13 end14 15 4 describe 'signature validation' do 16 5 it { is_expected.not_to eq(nil) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_re_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'validate_re' do 4 after(:all) do5 ENV.delete('STDLIB_LOG_DEPRECATIONS')6 end7 8 # Checking for deprecation warning9 it 'should display a single deprecation' do10 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"11 scope.expects(:warning).with(includes('This method is deprecated'))12 is_expected.to run.with_params('', '')13 end14 15 4 describe 'signature validation' do 16 5 it { is_expected.not_to eq(nil) } … … 29 18 30 19 describe 'invalid inputs' do 20 it { 21 pending('should implement stricter type checking') 22 is_expected.to run.with_params([], '').and_raise_error(Puppet::ParseError, /is not a String/) 23 } 24 it { 25 pending('should implement stricter type checking') 26 is_expected.to run.with_params('', {}).and_raise_error(Puppet::ParseError, /is not an Array/) 27 } 28 it { 29 pending('should implement stricter type checking') 30 is_expected.to run.with_params('', '', []).and_raise_error(Puppet::ParseError, /is not a String/) 31 } 32 it { 33 pending('should implement stricter type checking') 34 is_expected.to run.with_params(nil, nil).and_raise_error(Puppet::ParseError, /is not a String/) 35 } 31 36 it { is_expected.to run.with_params('', []).and_raise_error(Puppet::ParseError, /does not match/) } 32 37 it { is_expected.to run.with_params('one', 'two').and_raise_error(Puppet::ParseError, /does not match/) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_slength_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'validate_slength' do 4 after(:all) do5 ENV.delete('STDLIB_LOG_DEPRECATIONS')6 end7 8 # Checking for deprecation warning9 it 'should display a single deprecation' do10 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"11 scope.expects(:warning).with(includes('This method is deprecated'))12 is_expected.to run.with_params('1234567890', 10)13 end14 15 4 describe 'signature validation' do 16 5 it { is_expected.not_to eq(nil) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/validate_string_spec.rb
rad28f83 rbcf0be5 2 2 3 3 describe 'validate_string' do 4 after(:all) do5 ENV.delete('STDLIB_LOG_DEPRECATIONS')6 end7 8 # Checking for deprecation warning9 it 'should display a single deprecation' do10 ENV['STDLIB_LOG_DEPRECATIONS'] = "true"11 scope.expects(:warning).with(includes('This method is deprecated'))12 is_expected.to run.with_params('', '')13 end14 15 4 describe 'signature validation' do 16 5 it { is_expected.not_to eq(nil) } … … 19 8 describe 'valid inputs' do 20 9 it { is_expected.to run.with_params('') } 21 it { is_expected.to run.with_params(nil) }22 10 it { is_expected.to run.with_params('one') } 23 11 it { is_expected.to run.with_params('one', 'two') } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/values_at_spec.rb
rad28f83 rbcf0be5 31 31 end 32 32 33 context 'when requesting a single item using UTF8 and double byte characters' do34 it { is_expected.to run.with_params(['ẩ', 'β', 'с', 'ď'], 0).and_return(['ẩ']) }35 it { is_expected.to run.with_params(['文', '字', 'の', '値'], 2).and_return(['の']) }36 end37 38 33 context 'when requesting multiple items' do 39 34 it { is_expected.to run.with_params([0, 1, 2], [1, -1]).and_raise_error(Puppet::ParseError, /Unknown format of given index/) } -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/values_spec.rb
rad28f83 rbcf0be5 17 17 expect(result).to match_array(['value1', 'value2', 'value2']) 18 18 end 19 20 it 'should run with UTF8 and double byte characters' do21 result = subject.call([{ 'かぎ' => '使用', 'ҝĕұ' => '√ẩŀứệ', 'ҝĕұďŭрļǐçằťè' => '√ẩŀứệ' }])22 expect(result).to match_array(['使用', '√ẩŀứệ', '√ẩŀứệ'])23 end24 19 end -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/functions/zip_spec.rb
rad28f83 rbcf0be5 13 13 it { is_expected.to run.with_params([1,2,3], [4,5,6], false).and_return([[1,4], [2,5], [3,6]]) } 14 14 it { is_expected.to run.with_params([1,2,3], [4,5,6], true).and_return([1, 4, 2, 5, 3, 6]) } 15 16 context 'should run with UTF8 and double byte characters' do17 it { is_expected.to run.with_params(['ầ', 'ь', 'ć'], ['đ', 'ề', 'ƒ']).and_return([['ầ','đ'], ['ь','ề'], ['ć', 'ƒ']]) }18 it { is_expected.to run.with_params(['ペ', '含', '値'], ['ッ', '文', 'イ']).and_return([['ペ','ッ'], ['含','文'], ['値', 'イ']]) }19 end20 15 end 21 -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/spec_helper_acceptance.rb
rad28f83 rbcf0be5 1 1 #! /usr/bin/env ruby -S rspec 2 require 'puppet'3 2 require 'beaker-rspec' 4 3 require 'beaker/puppet_install_helper' 5 require 'beaker/module_install_helper' 4 5 UNSUPPORTED_PLATFORMS = [] 6 6 7 7 run_puppet_install_helper 8 install_ca_certs unless ENV['PUPPET_INSTALL_TYPE'] =~ /pe/i9 install_module_on(hosts)10 install_module_dependencies_on(hosts)11 8 12 9 RSpec.configure do |c| 10 # Project root 11 proj_root = File.expand_path(File.join(File.dirname(__FILE__), '..')) 12 13 13 # Readable test descriptions 14 14 c.formatter = :documentation … … 16 16 # Configure all nodes in nodeset 17 17 c.before :suite do 18 if ENV['FUTURE_PARSER'] == 'yes' 19 default[:default_apply_opts] ||= {} 20 default[:default_apply_opts].merge!({:parser => 'future'}) 21 end 22 23 copy_root_module_to(default, :source => proj_root, :module_name => 'stdlib') 18 24 end 25 end 26 27 def is_future_parser_enabled? 28 if default[:type] == 'aio' 29 return true 30 elsif default[:default_apply_opts] 31 return default[:default_apply_opts][:parser] == 'future' 32 end 33 return false 19 34 end 20 35 -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/spec_helper_local.rb
rad28f83 rbcf0be5 1 # automatically load any shared examples or contexts2 Dir["./spec/support/**/*.rb"].sort.each { |f| require f }3 1 4 2 # hack to enable all the expect syntax (like allow_any_instance_of) in rspec-puppet examples -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/unit/puppet/provider/file_line/ruby_spec.rb
rad28f83 rbcf0be5 364 364 end 365 365 366 it 'should find a line to match' do367 File.open(@tmpfile, 'w') do |fh|368 fh.write("foo1\nfoo\nfoo2")369 end370 expect(@provider.exists?).to be_truthy371 end372 373 366 it 'should remove one line if it matches' do 374 367 File.open(@tmpfile, 'w') do |fh| -
src/puppetcode/environments/gnuboat/modules/stdlib/spec/unit/puppet/type/file_line_spec.rb
rad28f83 rbcf0be5 3 3 require 'tempfile' 4 4 describe Puppet::Type.type(:file_line) do 5 let :tmp_path do6 if Puppet::Util::Platform.windows?7 'C:\tmp\path'8 else9 '/tmp/path'10 end11 end12 let :my_path do13 if Puppet::Util::Platform.windows?14 'C:\my\path'15 else16 '/my/path'17 end18 end19 5 let :file_line do 20 Puppet::Type.type(:file_line).new(:name => 'foo', :line => 'line', :path => tmp_path)6 Puppet::Type.type(:file_line).new(:name => 'foo', :line => 'line', :path => '/tmp/path') 21 7 end 22 8 it 'should accept a line and path' do 23 9 file_line[:line] = 'my_line' 24 10 expect(file_line[:line]).to eq('my_line') 25 file_line[:path] = my_path26 expect(file_line[:path]).to eq( my_path)11 file_line[:path] = '/my/path' 12 expect(file_line[:path]).to eq('/my/path') 27 13 end 28 14 it 'should accept a match regex' do … … 34 20 Puppet::Type.type(:file_line).new( 35 21 :name => 'foo', 36 :path => my_path,22 :path => '/my/path', 37 23 :line => 'foo=bar', 38 24 :match => '^bar=blah$' … … 43 29 Puppet::Type.type(:file_line).new( 44 30 :name => 'foo', 45 :path => my_path,31 :path => '/my/path', 46 32 :line => 'foo=bar', 47 33 :match => '^\s*foo=.*$' 48 34 )}.not_to raise_error 49 35 end 50 it 'should accept utf8 characters' do51 expect {52 Puppet::Type.type(:file_line).new(53 :name => 'ƒồỗ',54 :path => my_path,55 :line => 'ƒồỗ=ьåя',56 :match => '^ьåя=βļάħ$'57 )}.not_to raise_error58 end59 it 'should accept double byte characters' do60 expect {61 Puppet::Type.type(:file_line).new(62 :name => 'フーバー',63 :path => my_path,64 :line => 'この=それ',65 :match => '^この=ああ$'66 )}.not_to raise_error67 end68 36 it 'should accept posix filenames' do 69 file_line[:path] = tmp_path70 expect(file_line[:path]).to eq( tmp_path)37 file_line[:path] = '/tmp/path' 38 expect(file_line[:path]).to eq('/tmp/path') 71 39 end 72 40 it 'should not accept unqualified path' do … … 74 42 end 75 43 it 'should require that a line is specified' do 76 expect { Puppet::Type.type(:file_line).new(:name => 'foo', :path => tmp_path) }.to raise_error(Puppet::Error, /line is a required attribute/)44 expect { Puppet::Type.type(:file_line).new(:name => 'foo', :path => '/tmp/file') }.to raise_error(Puppet::Error, /line is a required attribute/) 77 45 end 78 46 it 'should not require that a line is specified when matching for absence' do 79 expect { Puppet::Type.type(:file_line).new(:name => 'foo', :path => tmp_path, :ensure => :absent, :match_for_absence => :true, :match => 'match') }.not_to raise_error47 expect { Puppet::Type.type(:file_line).new(:name => 'foo', :path => '/tmp/file', :ensure => :absent, :match_for_absence => :true, :match => 'match') }.not_to raise_error 80 48 end 81 49 it 'should require that a file is specified' do … … 88 56 expect(file_line[:replace]).to eq :true 89 57 end 90 it 'should default to encoding => UTF-8' do 91 expect(file_line[:encoding]).to eq 'UTF-8' 92 end 93 it 'should accept encoding => iso-8859-1' do 94 expect { Puppet::Type.type(:file_line).new(:name => 'foo', :path => tmp_path, :ensure => :present, :encoding => 'iso-8859-1', :line => 'bar') }.not_to raise_error 95 end 58 96 59 it "should autorequire the file it manages" do 97 60 catalog = Puppet::Resource::Catalog.new 98 file = Puppet::Type.type(:file).new(:name => tmp_path)61 file = Puppet::Type.type(:file).new(:name => "/tmp/path") 99 62 catalog.add_resource file 100 63 catalog.add_resource file_line 101 64 102 65 relationship = file_line.autorequire.find do |rel| 103 (rel.source.to_s == "File[ #{tmp_path}]") and (rel.target.to_s == file_line.to_s)66 (rel.source.to_s == "File[/tmp/path]") and (rel.target.to_s == file_line.to_s) 104 67 end 105 68 expect(relationship).to be_a Puppet::Relationship
Note:
See TracChangeset
for help on using the changeset viewer.
