Skip to content

Commit 68c991f

Browse files
test(fetch): give Test 13 its own load_today/car_charging_energy args (#5318 review)
The stand-ins only answer for load_today and car_charging_energy, so set both on the fresh instance instead of relying on coverage/apps.yaml, and drop ge_cloud_data so the load history cannot take the GE Cloud path that bypasses minute_data_load(). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent e7a25f5 commit 68c991f

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

‎apps/predbat/tests/test_car_energy_reported_load.py‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -208,6 +208,11 @@ def _test_fetch_only_checks_live_plan():
208208
print("Test 13: fetch_sensor_data() only runs the check for the live plan, not compare.py's save=False runs")
209209
failed = False
210210
fresh = create_predbat()
211+
# Configure the two sensors the stand-ins answer for, rather than relying on coverage/apps.yaml, and keep the
212+
# load history off the GE Cloud path, which would bypass minute_data_load()
213+
fresh.args["load_today"] = "sensor.test_load_today"
214+
fresh.args["car_charging_energy"] = "sensor.test_car_charging_energy"
215+
fresh.args.pop("ge_cloud_data", None)
211216
# Sensor history where the charger is evidently outside the load sensor. The test HA history carries no
212217
# last_updated, so the history readers are stood in for: load_today and car_charging_energy get these series,
213218
# everything else nothing.

0 commit comments

Comments
 (0)