simple-message-channels/test/test_smc.py
Luke Murphy 1c67ca74e4
Some checks failed
continuous-integration/drone/push Build is failing
Spec out first steps, nothing works yet
2020-06-30 15:09:04 +02:00

11 lines
335 B
Python

async def test_send_recv(smc):
channel, type, message = 0, 0, b"abc"
payload = await smc.send(channel, type, message)
assert isinstance(payload, bytes)
async with smc.recv(payload) as response:
assert response.channel == channel
assert response.type == type
assert response.message == message