|
9 | 9 | from modules.common.evse import Evse |
10 | 10 | from modules.common.hardware_check import ( |
11 | 11 | EVSE_BROKEN, LAN_ADAPTER_BROKEN, METER_BROKEN_VOLTAGES, METER_IMPLAUSIBLE_VALUE, METER_NO_SERIAL_NUMBER, |
12 | | - METER_PROBLEM, OPEN_TICKET, USB_ADAPTER_BROKEN, SeriesHardwareCheckMixin, _check_meter_values) |
| 12 | + METER_PROBLEM, METER_VOLTAGE_TOO_HIGH, METER_VOLTAGE_TOO_LOW, OPEN_TICKET, USB_ADAPTER_BROKEN, |
| 13 | + SeriesHardwareCheckMixin, _check_meter_values) |
13 | 14 | from modules.common.modbus import NO_CONNECTION, ModbusSerialClient_, ModbusTcpClient_ |
14 | 15 | from modules.conftest import SAMPLE_IP, SAMPLE_PORT |
15 | 16 | from modules.internal_chargepoint_handler.clients import ClientHandler |
@@ -97,6 +98,8 @@ def test_hardware_check_succeeds(monkeypatch): |
97 | 98 | pytest.param([0, 230, 230], 0, METER_BROKEN_VOLTAGES.format([0, 230, 230]), id="dreiphasig, L1 defekt"), |
98 | 99 | pytest.param([230, 0, 230], 0, METER_BROKEN_VOLTAGES.format([230, 0, 230]), id="dreiphasig, L2 defekt"), |
99 | 100 | pytest.param([230]*3, 100, METER_PROBLEM, id="Phantom-Leistung"), |
| 101 | + pytest.param([261, 230, 230], 0, METER_VOLTAGE_TOO_HIGH.format([261, 230, 230]), id="Spannung zu hoch"), |
| 102 | + pytest.param([230, 230, 199], 0, METER_VOLTAGE_TOO_LOW.format([230, 230, 199]), id="Spannung zu niedrig"), |
100 | 103 | ] |
101 | 104 | ) |
102 | 105 | def test_check_meter_values_voltages(voltages, power, expected_msg, monkeypatch): |
|
0 commit comments