Module: Canned::Context::Matchers::The
- Included in:
- Default
- Defined in:
- lib/canned/context/matchers/the.rb
Instance Method Summary collapse
-
#the(_name, _options = {}, &_block) ⇒ Object
Loads an actor and returns an actor context.
Instance Method Details
#the(_name, _options = {}, &_block) ⇒ Object
Loads an actor and returns an actor context.
of that returned by this function.
14 15 16 17 18 19 20 |
# File 'lib/canned/context/matchers/the.rb', line 14 def the(_name, ={}, &_block) _chain_context(Canned::Context::Actor, _block) do |stack| actor = @ctx.actors[_name] next false if actor.nil? stack.push(:actor, .fetch(:as, _name), actor) end end |