Sha256: 239680ad8b2f2f4f50b68f573207c6570ee560c66b2d51d872fca0d444c12a9c
Contents?: true
Size: 562 Bytes
Versions: 19
Compression:
Stored size: 562 Bytes
Contents
module WebsocketRails class SpecHelperEvent < Event attr_reader :dispatcher, :triggered alias :triggered? :triggered def initialize(event_name,options={}) super(event_name, options) @triggered = false @dispatcher = Dispatcher.new(nil) end def trigger @triggered = true end def dispatch @dispatcher.dispatch(self) self end def connection OpenStruct.new(:id => 1) end end end def create_event(name, data) WebsocketRails::SpecHelperEvent.new(name, {data: data}) end
Version data entries
19 entries across 19 versions & 3 rubygems