Module: RSpecSystemPuppet::Helpers
- Includes:
- RSpecSystem::Helpers
- Defined in:
- lib/rspec-system-puppet/helpers.rb
Overview
This module contains the methods provide by rspec-system-puppet
Instance Method Summary collapse
-
#facter(opts = {}) {|result| ... } ⇒ RSpecSystemPuppet::Helpers::Facter
Run facter on a remote machine.
-
#puppet_agent(opts = {}) {|result| ... } ⇒ RSpecSystem::Helpers::PuppetAgent
Run puppet agent.
-
#puppet_apply(opts) {|result| ... } ⇒ RSpecSystem::Helpers::PuppetApply
Run puppet DSL code directly with ‘puppet apply`.
-
#puppet_install(opts = {}) {|result| ... } ⇒ RspecSystemPuppet::Helpers::PuppetInstall
Basic helper to install puppet.
-
#puppet_master_install(opts = {}) {|result| ... } ⇒ RspecSystemPuppet::Helpers::PuppetMasterInstall
Basic helper to install a puppet master.
-
#puppet_module_install(opts) {|result| ... } ⇒ RSpecSystem::Helpers::PuppetModuleInstall
Helper to copy a module onto a node from source.
-
#puppet_resource(opts) {|result| ... } ⇒ RSpecSystem::Helpers::PuppetResource
Runs puppet resource commands.
Instance Method Details
#facter(opts = {}) {|result| ... } ⇒ RSpecSystemPuppet::Helpers::Facter
Run facter on a remote machine
119 120 121 |
# File 'lib/rspec-system-puppet/helpers.rb', line 119 def facter(opts = {}, &block) RSpecSystemPuppet::Helpers::Facter.new(opts, self, &block) end |
#puppet_agent(opts = {}) {|result| ... } ⇒ RSpecSystem::Helpers::PuppetAgent
Run puppet agent
53 54 55 |
# File 'lib/rspec-system-puppet/helpers.rb', line 53 def puppet_agent(opts = {}, &block) RSpecSystemPuppet::Helpers::PuppetAgent.new(opts, self, &block) end |
#puppet_apply(opts) {|result| ... } ⇒ RSpecSystem::Helpers::PuppetApply
Run puppet DSL code directly with ‘puppet apply`.
This takes a string of PuppetDSL code, uploads it to the test server and executes it directly with ‘puppet apply`.
103 104 105 106 107 108 109 |
# File 'lib/rspec-system-puppet/helpers.rb', line 103 def puppet_apply(opts, &block) if opts.is_a?(String) opts = {:code => opts} end RSpecSystemPuppet::Helpers::PuppetApply.new(opts, self, &block) end |
#puppet_install(opts = {}) {|result| ... } ⇒ RspecSystemPuppet::Helpers::PuppetInstall
Basic helper to install puppet
21 22 23 |
# File 'lib/rspec-system-puppet/helpers.rb', line 21 def puppet_install(opts = {}, &block) RSpecSystemPuppet::Helpers::PuppetInstall.new(opts, self, &block) end |
#puppet_master_install(opts = {}) {|result| ... } ⇒ RspecSystemPuppet::Helpers::PuppetMasterInstall
Basic helper to install a puppet master
32 33 34 |
# File 'lib/rspec-system-puppet/helpers.rb', line 32 def puppet_master_install(opts = {}, &block) RSpecSystemPuppet::Helpers::PuppetMasterInstall.new(opts, self, &block) end |
#puppet_module_install(opts) {|result| ... } ⇒ RSpecSystem::Helpers::PuppetModuleInstall
Helper to copy a module onto a node from source
64 65 66 |
# File 'lib/rspec-system-puppet/helpers.rb', line 64 def puppet_module_install(opts, &block) RSpecSystemPuppet::Helpers::PuppetModuleInstall.new(opts, self, &block) end |
#puppet_resource(opts) {|result| ... } ⇒ RSpecSystem::Helpers::PuppetResource
Runs puppet resource commands
75 76 77 78 79 80 81 |
# File 'lib/rspec-system-puppet/helpers.rb', line 75 def puppet_resource(opts, &block) if opts.is_a?(String) opts = {:resource => opts} end RSpecSystemPuppet::Helpers::PuppetResource.new(opts, self, &block) end |