mirror of
https://github.com/kc1awv/rrcd.git
synced 2026-07-16 13:18:11 -07:00
add ACTION message type and capability signaling
This commit is contained in:
+9
-1
@@ -1,5 +1,5 @@
|
||||
from rrcd.codec import decode, encode
|
||||
from rrcd.constants import T_MSG
|
||||
from rrcd.constants import T_ACTION, T_MSG
|
||||
from rrcd.envelope import make_envelope, validate_envelope
|
||||
|
||||
|
||||
@@ -9,3 +9,11 @@ def test_codec_round_trip() -> None:
|
||||
decoded = decode(data)
|
||||
assert decoded == env
|
||||
validate_envelope(decoded)
|
||||
|
||||
|
||||
def test_codec_round_trip_action() -> None:
|
||||
env = make_envelope(T_ACTION, src=b"peer", room="#general", body="waves")
|
||||
data = encode(env)
|
||||
decoded = decode(data)
|
||||
assert decoded == env
|
||||
validate_envelope(decoded)
|
||||
|
||||
Reference in New Issue
Block a user