Add coordinator data to Renault diagnostics (#64783)
* Add coordinator data to renault diagnostics * Adjust tests * Adjust tests * Add GPS coordinates to redacted information
This commit is contained in:
parent
17d7dc991f
commit
aa9ccc7dfb
2 changed files with 43 additions and 7 deletions
|
@ -134,6 +134,31 @@ VEHICLE_DETAILS = {
|
|||
"radioCode": REDACTED,
|
||||
}
|
||||
|
||||
VEHICLE_DATA = {
|
||||
"battery": {
|
||||
"batteryAutonomy": 141,
|
||||
"batteryAvailableEnergy": 31,
|
||||
"batteryCapacity": 0,
|
||||
"batteryLevel": 60,
|
||||
"batteryTemperature": 20,
|
||||
"chargingInstantaneousPower": 27,
|
||||
"chargingRemainingTime": 145,
|
||||
"chargingStatus": 1.0,
|
||||
"plugStatus": 1,
|
||||
"timestamp": "2020-01-12T21:40:16Z",
|
||||
},
|
||||
"charge_mode": {
|
||||
"chargeMode": "always",
|
||||
},
|
||||
"cockpit": {
|
||||
"totalMileage": 49114.27,
|
||||
},
|
||||
"hvac_status": {
|
||||
"externalTemperature": 8.0,
|
||||
"hvacStatus": "off",
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
@pytest.mark.usefixtures("fixtures_with_data")
|
||||
@pytest.mark.parametrize("vehicle_type", ["zoe_40"], indirect=True)
|
||||
|
@ -154,7 +179,7 @@ async def test_entry_diagnostics(
|
|||
},
|
||||
"title": "Mock Title",
|
||||
},
|
||||
"vehicles": [VEHICLE_DETAILS],
|
||||
"vehicles": [{"details": VEHICLE_DETAILS, "data": VEHICLE_DATA}],
|
||||
}
|
||||
|
||||
|
||||
|
@ -174,4 +199,4 @@ async def test_device_diagnostics(
|
|||
|
||||
assert await get_diagnostics_for_device(
|
||||
hass, hass_client, config_entry, device
|
||||
) == {"details": VEHICLE_DETAILS}
|
||||
) == {"details": VEHICLE_DETAILS, "data": VEHICLE_DATA}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue