Module: Puppet::Util

Defined in:
lib/rspec-puppet/monkey_patches.rb

Defined Under Namespace

Modules: Platform

Class Method Summary collapse

Class Method Details

.get_env(name, mode = default_env) ⇒ Object



129
130
131
132
133
134
135
136
# File 'lib/rspec-puppet/monkey_patches.rb', line 129

def get_env(name, mode = default_env)
  if RSpec::Puppet.rspec_puppet_example?
    # use the actual platform, not the pretended
   old_get_env(name, Platform.actual_platform)
  else
   old_get_env(name, mode)
  end
end

.old_get_envObject



126
# File 'lib/rspec-puppet/monkey_patches.rb', line 126

alias :old_get_env :get_env