mirror of
https://github.com/home-assistant/core.git
synced 2025-11-13 04:50:17 +00:00
Use new style for built-in ws commmands (#21694)
* Use new style for built-in ws commmands * Lint
This commit is contained in:
@@ -5,7 +5,7 @@ from unittest.mock import patch, Mock
|
||||
from aiohttp import WSMsgType
|
||||
import pytest
|
||||
|
||||
from homeassistant.components.websocket_api import const, commands, messages
|
||||
from homeassistant.components.websocket_api import const, messages
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
@@ -56,7 +56,7 @@ def test_pending_msg_overflow(hass, mock_low_queue, websocket_client):
|
||||
for idx in range(10):
|
||||
yield from websocket_client.send_json({
|
||||
'id': idx + 1,
|
||||
'type': commands.TYPE_PING,
|
||||
'type': 'ping',
|
||||
})
|
||||
msg = yield from websocket_client.receive()
|
||||
assert msg.type == WSMsgType.close
|
||||
|
||||
Reference in New Issue
Block a user