Module: EventMachine::Spec::Bacon

Defined in:
lib/em-spec/bacon.rb

Class Method Summary collapse

Class Method Details

.spec(args, blk) ⇒ Object



35
36
37
38
39
40
41
42
43
# File 'lib/em-spec/bacon.rb', line 35

def self.spec( args, blk )
  EM.run do
    ::Bacon.summary_on_exit
    ($em_spec_fiber = Fiber.new{
                        ::Bacon::FiberedContext.new(args.join(' '), &blk).run
                        EM.stop_event_loop
                      }).resume
  end
end