class PoiseRuby::RubyProviders::Dummy

Inversion provider for the `ruby_runtime` resource to use a fake Ruby, for use in unit tests.

@since 2.1.0 @provides dummy

Public Class Methods

default_inversion_options(node, resource) click to toggle source
# File lib/poise_ruby/ruby_providers/dummy.rb, line 30
def self.default_inversion_options(node, resource)
  super.merge({
    # Manual overrides for dummy data.
    ruby_binary: ::File.join('', 'ruby'),
    ruby_environment: nil,
    gem_binary: nil,
  })
end

Public Instance Methods

action_install() click to toggle source

The `install` action for the `ruby_runtime` resource.

@return [void]

# File lib/poise_ruby/ruby_providers/dummy.rb, line 42
def action_install
  # This space left intentionally blank.
end
action_uninstall() click to toggle source

The `uninstall` action for the `ruby_runtime` resource.

@return [void]

# File lib/poise_ruby/ruby_providers/dummy.rb, line 49
def action_uninstall
  # This space left intentionally blank.
end
gem_binary() click to toggle source

Path to the non-existent gem.

@return [String]

# File lib/poise_ruby/ruby_providers/dummy.rb, line 70
def gem_binary
  options['gem_binary'] || super
end
ruby_binary() click to toggle source

Path to the non-existent ruby.

@return [String]

# File lib/poise_ruby/ruby_providers/dummy.rb, line 56
def ruby_binary
  options['ruby_binary']
end
ruby_environment() click to toggle source

Environment for the non-existent Ruby.

@return [String]

# File lib/poise_ruby/ruby_providers/dummy.rb, line 63
def ruby_environment
  options['ruby_environment'] || super
end