lib/angelo/minitest/helpers.rb in angelo-0.4.1 vs lib/angelo/minitest/helpers.rb in angelo-0.5.0

- old
+ new

@@ -132,21 +132,24 @@ end class Reactor include Celluloid::IO extend Cellper + def wait_for_stop + every(0.01){ terminate if Reactor.stop? } + end end - class ActorPool + class Actor include Celluloid extend Cellper end end class WebsocketHelper - include Celluloid::Logger + include Celluloid::Internals::Logger extend Forwardable def_delegator :@socket, :write def_delegators :@driver, :binary, :close, :text @@ -190,11 +193,14 @@ WS_URL % [@addr, @port] + @path end def go @driver.start - while msg = @socket.readpartial(4096) - @driver.parse msg + begin + while msg = @socket.readpartial(4096) + @driver.parse msg + end + rescue EOFError, SystemCallError => e end end end