Method: Defi.send

Defined in:
lib/defi.rb

.send(method, *args, **kwargs, &block) ⇒ Challenge

Expectations are built with this method.

Examples:

A :foo challenge

send(:foo) # => #<Defi::Challenge:0x007f96a40925f8 @method=:foo, @args=[]>

Parameters:

  • method (#to_sym)

    The method to send to an object.

  • args (Array)

    Any arguments of the method.

  • kwargs (Hash)

    Any keyword arguments of the method.

  • block (Proc)

    Any block argument of the method.

Returns:



17
18
19
# File 'lib/defi.rb', line 17

def self.send(method, *args, **kwargs, &block)
  Challenge.new(method, *args, **kwargs, &block)
end