Commit 1bca75a7 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 8be91f31
...@@ -263,7 +263,6 @@ func (t *T) queuenak(msg *_Msg, why string) { ...@@ -263,7 +263,6 @@ func (t *T) queuenak(msg *_Msg, why string) {
// //
// It should be called not more than once. // It should be called not more than once.
// Before SetEventRouter is called, all events go to "default" stream. // Before SetEventRouter is called, all events go to "default" stream.
// XXX naming
func (t *T) SetEventRouter(routeEvent func(event interface{}) (stream string)) { func (t *T) SetEventRouter(routeEvent func(event interface{}) (stream string)) {
t.mu.Lock() t.mu.Lock()
defer t.mu.Unlock() defer t.mu.Unlock()
...@@ -274,16 +273,13 @@ func (t *T) SetEventRouter(routeEvent func(event interface{}) (stream string)) { ...@@ -274,16 +273,13 @@ func (t *T) SetEventRouter(routeEvent func(event interface{}) (stream string)) {
t.routeEvent = routeEvent t.routeEvent = routeEvent
} }
// t.RxEvent should be synchronously called from test system when an event // RxEvent should be synchronously called from test system when an event occurs.
// occurs.
// //
// The sequential process of the test system where event originated should be // The sequential process of the test system where event originated should be
// paused until RxEvent returns. This requirement can be easily met via ... XXX // paused until RxEvent returns. This requirement can be usually met via
// inserting t.RxEvent() call into the code the produces the event.
// //
// // XXX naming; NewEvent? IncomingEvent? OnEvent?
// XXX doc; naming
// XXX NewEvent? IncomingEvent? OnEvent?
// XXX pass events in not via t (via something dedicated)?
func (t *T) RxEvent(event interface{}) { func (t *T) RxEvent(event interface{}) {
t0 := time.Now() t0 := time.Now()
stream := "" stream := ""
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment