userver: samples/websocket_service/tests/test_websocket.py
⚠️ This is the documentation for an old userver version. Click here to switch to the latest version.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages Concepts
samples/websocket_service/tests/test_websocket.py
1# /// [Functional test]
2async def test_echo(websocket_client):
3 async with websocket_client.get('chat') as chat:
4 await chat.send('hello')
5 response = await chat.recv()
6 assert response == 'hello'
7 # /// [Functional test]