Skip to content

Commit

Permalink
Fix solarlog test RuntimeWarning (#125504)
Browse files Browse the repository at this point in the history
  • Loading branch information
cdce8p authored Sep 8, 2024
1 parent 1f80b80 commit d3badb8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/components/solarlog/conftest.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""Test helpers."""

from collections.abc import Generator
from unittest.mock import AsyncMock, patch
from unittest.mock import AsyncMock, MagicMock, patch

import pytest
from solarlog_cli.solarlog_models import InverterData, SolarlogData
Expand Down Expand Up @@ -53,6 +53,7 @@ def mock_solarlog_connector():
data.inverter_data = INVERTER_DATA

mock_solarlog_api = AsyncMock()
mock_solarlog_api.set_enabled_devices = MagicMock()
mock_solarlog_api.test_connection.return_value = True
mock_solarlog_api.update_data.return_value = data
mock_solarlog_api.update_device_list.return_value = INVERTER_DATA
Expand Down

0 comments on commit d3badb8

Please sign in to comment.