Class: Loom::Shell::FakeApi
Instance Attribute Summary collapse
-
#cmd_execution_args ⇒ Object
readonly
Returns the value of attribute cmd_execution_args.
-
#cmd_executions ⇒ Object
readonly
Returns the value of attribute cmd_executions.
Instance Method Summary collapse
-
#initialize ⇒ FakeApi
constructor
Fake Override.
- #method_missing(name, *args, &block) ⇒ Object
Methods inherited from Api
Constructor Details
#initialize ⇒ FakeApi
Fake Override
37 38 39 40 |
# File 'lib/loom/shell/api.rb', line 37 def initialize @cmd_executions = [] @cmd_execution_args = [] end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, *args, &block) ⇒ Object
43 44 45 46 47 |
# File 'lib/loom/shell/api.rb', line 43 def method_missing(name, *args, &block) @cmd_executions.push name @cmd_execution_args.push args self end |
Instance Attribute Details
#cmd_execution_args ⇒ Object (readonly)
Returns the value of attribute cmd_execution_args.
41 42 43 |
# File 'lib/loom/shell/api.rb', line 41 def cmd_execution_args @cmd_execution_args end |
#cmd_executions ⇒ Object (readonly)
Returns the value of attribute cmd_executions.
41 42 43 |
# File 'lib/loom/shell/api.rb', line 41 def cmd_executions @cmd_executions end |