

def test_event():
    (server, session, transport, conn) = _get_test_environment()
    transport.recv(proto.event(None, 'test', None, a=10, b=20))
    session.recv('5:::{"name":"test", "args":[10, 20]}')
    eq_(conn.pop_event(), ('test', dict(a=10, b=20)))
    eq_(transport.pop_outgoing(), proto.event(None, 'test', None, a=10, b=20))

dataset/ETHPy150Open mrjoes/tornadio2/tests/session_test.py test_event/VarMisuse@47/54 `transport`->`session`