mirror of https://gitlab.com/litecord/litecord.git
test_websocket: use _close on test_ready
This commit is contained in:
parent
07c66d121a
commit
0e57ad9633
|
|
@ -72,7 +72,7 @@ async def test_gw(test_cli):
|
|||
assert isinstance(hello['d']['heartbeat_interval'], int)
|
||||
assert isinstance(hello['d']['_trace'], list)
|
||||
|
||||
await conn.close(1000, 'test end')
|
||||
await _close(conn)
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
|
|
@ -94,9 +94,10 @@ async def test_ready(test_cli):
|
|||
try:
|
||||
await _json(conn)
|
||||
assert True
|
||||
await conn.close(1000, 'test end')
|
||||
except (Exception, websockets.ConnectionClosed):
|
||||
assert False
|
||||
finally:
|
||||
await _close(conn)
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
|
|
|
|||
Loading…
Reference in New Issue