Enable sentry reporting for zwave_js (#71719)
* Enable sentry reporting for zwave_js * Fix test
This commit is contained in:
parent
684fe242d9
commit
ca52aa47aa
2 changed files with 5 additions and 2 deletions
|
@ -95,6 +95,7 @@ def get_value_of_zwave_value(value: ZwaveValue | None) -> Any | None:
|
|||
async def async_enable_statistics(client: ZwaveClient) -> None:
|
||||
"""Enable statistics on the driver."""
|
||||
await client.driver.async_enable_statistics("Home Assistant", HA_VERSION)
|
||||
await client.driver.async_enable_error_reporting()
|
||||
|
||||
|
||||
@callback
|
||||
|
|
|
@ -3172,10 +3172,12 @@ async def test_data_collection(hass, client, integration, hass_ws_client):
|
|||
result = msg["result"]
|
||||
assert result is None
|
||||
|
||||
assert len(client.async_send_command.call_args_list) == 1
|
||||
args = client.async_send_command.call_args[0][0]
|
||||
assert len(client.async_send_command.call_args_list) == 2
|
||||
args = client.async_send_command.call_args_list[0][0][0]
|
||||
assert args["command"] == "driver.enable_statistics"
|
||||
assert args["applicationName"] == "Home Assistant"
|
||||
args = client.async_send_command.call_args_list[1][0][0]
|
||||
assert args["command"] == "driver.enable_error_reporting"
|
||||
assert entry.data[CONF_DATA_COLLECTION_OPTED_IN]
|
||||
|
||||
client.async_send_command.reset_mock()
|
||||
|
|
Loading…
Add table
Reference in a new issue