Class: PoiseRuby::RubyProviders::Dummy
- Defined in:
- lib/poise_ruby/ruby_providers/dummy.rb
Overview
Inversion provider for the ruby_runtime
resource to use a fake Ruby,
for use in unit tests.
Class Method Summary collapse
Instance Method Summary collapse
-
#action_install
The
install
action for theruby_runtime
resource. -
#action_uninstall
The
uninstall
action for theruby_runtime
resource. -
#gem_binary ⇒ String
Path to the non-existent gem.
-
#ruby_binary ⇒ String
Path to the non-existent ruby.
-
#ruby_environment ⇒ String
Environment for the non-existent Ruby.
Class Method Details
.default_inversion_options(node, resource) ⇒ Object
30 31 32 33 34 35 36 37 |
# File 'lib/poise_ruby/ruby_providers/dummy.rb', line 30 def self.(node, resource) super.merge({ # Manual overrides for dummy data. ruby_binary: ::File.join('', 'ruby'), ruby_environment: nil, gem_binary: nil, }) end |
Instance Method Details
#action_install
This method returns an undefined value.
The install
action for the ruby_runtime
resource.
42 43 44 |
# File 'lib/poise_ruby/ruby_providers/dummy.rb', line 42 def action_install # This space left intentionally blank. end |
#action_uninstall
This method returns an undefined value.
The uninstall
action for the ruby_runtime
resource.
49 50 51 |
# File 'lib/poise_ruby/ruby_providers/dummy.rb', line 49 def action_uninstall # This space left intentionally blank. end |
#gem_binary ⇒ String
Path to the non-existent gem.
70 71 72 |
# File 'lib/poise_ruby/ruby_providers/dummy.rb', line 70 def gem_binary ['gem_binary'] || super end |
#ruby_binary ⇒ String
Path to the non-existent ruby.
56 57 58 |
# File 'lib/poise_ruby/ruby_providers/dummy.rb', line 56 def ruby_binary ['ruby_binary'] end |
#ruby_environment ⇒ String
Environment for the non-existent Ruby.
63 64 65 |
# File 'lib/poise_ruby/ruby_providers/dummy.rb', line 63 def ruby_environment ['ruby_environment'] || super end |