File tree 1 file changed +17
-0
lines changed
1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -974,6 +974,23 @@ def test_get_load_forecast_typical(self):
974
974
)
975
975
self .assertEqual (P_load_forecast .index .tz , self .fcst .time_zone )
976
976
self .assertEqual (len (self .P_PV_forecast ), len (P_load_forecast ))
977
+ # Relaunch this test but changing the timestep to 1h
978
+ params = self .fcst .params
979
+ params ['retrieve_hass_conf' ]['optimization_time_step' ] = 60
980
+ self .retrieve_hass_conf ["optimization_time_step" ] = pd .Timedelta ('1h' )
981
+ fcst = Forecast (
982
+ self .retrieve_hass_conf ,
983
+ self .optim_conf ,
984
+ self .plant_conf ,
985
+ params ,
986
+ emhass_conf ,
987
+ logger ,
988
+ get_data_from_file = self .get_data_from_file ,
989
+ )
990
+ self .assertTrue (len (fcst .forecast_dates ) == 24 )
991
+ P_load_forecast = fcst .get_load_forecast (method = "typical" )
992
+ self .assertIsInstance (P_load_forecast , pd .core .series .Series )
993
+ self .assertTrue (len (P_load_forecast ) == len (fcst .forecast_dates ))
977
994
978
995
# Test load cost forecast dataframe output using saved csv referece file
979
996
def test_get_load_cost_forecast (self ):
You can’t perform that action at this time.
0 commit comments