]> gitweb.fluxo.info Git - puppet-stdlib.git/commit
(#13439) Fix MRI 1.9 issue with spec_helper
authorJeff McCune <jeff@puppetlabs.com>
Fri, 30 Mar 2012 06:04:12 +0000 (23:04 -0700)
committerJeff McCune <jeff@puppetlabs.com>
Fri, 30 Mar 2012 06:18:15 +0000 (23:18 -0700)
commit15c5fd1f41f5d6585edb1bb0adcae4c1c8bd2def
tree37e317b247770df92325bb7539b4a7cf76144d45
parentd22fbe32cd626091b32c8a0c0a8c83771a0c999a
(#13439) Fix MRI 1.9 issue with spec_helper

When using MRI 1.9.x the stdlib spec helper does not invoke because
Puppet.settings.private_methods returns symbols instead of strings.

This is a problem because we need to set default configuration settings
like Puppet[:vardir] when using the compiler.

This patch fixes the issue by simply checking the Puppet version.  This
seems a better choice than rescuing NoMethodError since the method might
be renamed or removed in the future.
spec/spec_helper.rb