Class | Spec::Example::ModuleInclusionWarnings::MethodDispatcher
In: | lib/spec/example/module_inclusion_warnings.rb
Parent: | Object

Thanks, Francis Hwang.

### Methods

call new respond_to?

### Public Class methods

new(mod, target=nil)

[Source]

        # File lib/spec/example/module_inclusion_warnings.rb, line 9
     9:         def initialize(mod, target=nil)
    10:           @mod = mod
    11:           @target = target
    12:         end

### Public Instance methods

call(sym, *args, &blk)

[Source]

        # File lib/spec/example/module_inclusion_warnings.rb, line 18
    18:         def call(sym, *args, &blk)
    19:           Kernel.warn("Modules will no longer be automatically included in RSpec version 1.1.4.  Called from #{caller[2]}")
    20:           @target.extend @mod
    21:           @target.send(sym, *args, &blk)
    22:         end

respond_to?(sym)

[Source]

        # File lib/spec/example/module_inclusion_warnings.rb, line 14
    14:         def respond_to?(sym)
    15:           @mod && @mod.instance_methods.include?(sym.to_s)
    16:         end

[Validate]