Fixing the api_streams sensor (#22200)
* Fire events with websocket messages. * Added tests to validate * Fixed api_streams sensor to use new sensor * Delete from coverageac as now works. * Removed websocket request event. * Use dispatcher instead of events. * Moved sensor to under websocket_api * Changes as per code review * Fixed tests. * Modified test * Patch
This commit is contained in:
1 parent
2b6e197deb
commit
1ddc65a0ce
8 files changed
+142
-168
No files matched your search
@@ -20,3 +20,7 @@ TYPE_RESULT = 'result'
|
||||
# Originally, this was just asyncio.CancelledError, but issue #9546 showed
|
||||
# that futures.CancelledErrors can also occur in some situations.
|
||||
CANCELLATION_ERRORS = (asyncio.CancelledError, futures.CancelledError)
|
||||
|
||||
# Event types
|
||||
SIGNAL_WEBSOCKET_CONNECTED = 'websocket_connected'
|
||||
SIGNAL_WEBSOCKET_DISCONNECTED = 'websocket_disconnected'
|
||||
Reference in new issue
Block a user