Class: Pester::Environment
- Inherits:
-
Object
- Object
- Pester::Environment
- Defined in:
- lib/pester/environment.rb
Instance Attribute Summary collapse
-
#options ⇒ Object
Returns the value of attribute options.
Instance Method Summary collapse
-
#initialize(opts) ⇒ Environment
constructor
A new instance of Environment.
- #method_missing(name, *args, &block) ⇒ Object
Constructor Details
#initialize(opts) ⇒ Environment
Returns a new instance of Environment.
5 6 7 |
# File 'lib/pester/environment.rb', line 5 def initialize(opts) @options = opts end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, *args, &block) ⇒ Object
9 10 11 12 13 14 15 |
# File 'lib/pester/environment.rb', line 9 def method_missing(name, *args, &block) if name.to_s.start_with?('retry') && args.empty? Pester.send(name, @options, &block) else super end end |
Instance Attribute Details
#options ⇒ Object
Returns the value of attribute options.
3 4 5 |
# File 'lib/pester/environment.rb', line 3 def @options end |