Add README, improve test coverage, and refactor battery model initialization with timestamp

This commit is contained in:
2026-09-22 18:26:12 +01:00
parent 99dd7feba6
commit 1e53a8c6c8
4 changed files with 59 additions and 16 deletions
+1
View File
@@ -5,6 +5,7 @@ from batterymodel.models.market import MarketState
def test_market():
this_market = MarketState()
this_market._last_key = datetime.datetime.strptime('01-01-2022 00:05', '%d-%m-%Y %H:%M')
this_market._market_data[datetime.datetime.strptime('01-01-2022 00:00', '%d-%m-%Y %H:%M')] = 11
this_market._market_data[datetime.datetime.strptime('01-01-2022 00:01', '%d-%m-%Y %H:%M')] = 12
this_market._market_data[datetime.datetime.strptime('01-01-2022 00:02', '%d-%m-%Y %H:%M')] = 13