diff --git a/livekit-rtc/tests/test_emitter.py b/livekit-rtc/tests/test_emitter.py index fb2616f3..830feb3a 100644 --- a/livekit-rtc/tests/test_emitter.py +++ b/livekit-rtc/tests/test_emitter.py @@ -51,16 +51,16 @@ def test_args(): emitter = EventEmitter[EventTypes]() - args_calls = [] + calls = [] @emitter.on("whatever") def on_whatever(first, second, third): - args_calls.append((first, second, third)) + calls.append((first, second, third)) emitter.emit("whatever", 1, 2, 3) emitter.emit("whatever", 1, 2, 3, 4, 5) # only 3 arguments will be passed - assert args_calls == [(1, 2, 3), (1, 2, 3)] + assert calls == [(1, 2, 3), (1, 2, 3)] with pytest.raises(TypeError): emitter.emit("whatever", 1, 2) @@ -71,16 +71,16 @@ def test_varargs(): emitter = EventEmitter[EventTypes]() - varargs_calls = [] + calls = [] @emitter.on("whatever") def on_whatever_varargs(*args): - varargs_calls.append(args) + calls.append(args) emitter.emit("whatever", 1, 2, 3, 4, 5) emitter.emit("whatever", 1, 2) - assert varargs_calls == [(1, 2, 3, 4, 5), (1, 2)] + assert calls == [(1, 2, 3, 4, 5), (1, 2)] def test_throw():