Class: Cucumber::Broadcaster

Inherits:
Object
  • Object
show all
Defined in:
lib/cucumber/broadcaster.rb

Instance Method Summary collapse

Constructor Details

#initialize(receivers = []) ⇒ Broadcaster

Returns a new instance of Broadcaster.



3
4
5
# File 'lib/cucumber/broadcaster.rb', line 3

def initialize(receivers = [])
  @receivers = receivers
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(method_name, *args) ⇒ Object



7
8
9
10
11
# File 'lib/cucumber/broadcaster.rb', line 7

def method_missing(method_name, *args)
  @receivers.map do |receiver|
    receiver.__send__(method_name, *args)
  end
end