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

.

parent 8be91f31
......@@ -263,7 +263,6 @@ func (t *T) queuenak(msg *_Msg, why string) {
//
// It should be called not more than once.
// Before SetEventRouter is called, all events go to "default" stream.
// XXX naming
func (t *T) SetEventRouter(routeEvent func(event interface{}) (stream string)) {
t.mu.Lock()
defer t.mu.Unlock()
......@@ -274,16 +273,13 @@ func (t *T) SetEventRouter(routeEvent func(event interface{}) (stream string)) {
t.routeEvent = routeEvent
}
// t.RxEvent should be synchronously called from test system when an event
// occurs.
// RxEvent should be synchronously called from test system when an event occurs.
//
// 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 doc; naming
// XXX NewEvent? IncomingEvent? OnEvent?
// XXX pass events in not via t (via something dedicated)?
// XXX naming; NewEvent? IncomingEvent? OnEvent?
func (t *T) RxEvent(event interface{}) {
t0 := time.Now()
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