Activate optimization test with 3 generations

This commit is contained in:
Michael Osthege
2024-10-07 19:52:48 +02:00
committed by Andreas
parent b6d0ef22f3
commit 3c1482c2c0
2 changed files with 10 additions and 5 deletions

View File

@@ -11,7 +11,6 @@ DIR_TESTDATA = Path(__file__).parent / "testdata"
@pytest.mark.parametrize(
"fn_in, fn_out", [("optimize_input_1.json", "optimize_result_1.json")]
)
@pytest.mark.skip(reason="Expensive - Skipped per default")
def test_optimize(fn_in, fn_out):
# Load input and output data
with open(DIR_TESTDATA / fn_in, "r") as f_in:
@@ -26,7 +25,9 @@ def test_optimize(fn_in, fn_out):
start_hour = 10
# Call the optimization function
ergebnis = opt_class.optimierung_ems(parameter=input_data, start_hour=start_hour)
ergebnis = opt_class.optimierung_ems(
parameter=input_data, start_hour=start_hour, ngen=3
)
# Assert that the output contains all expected entries.
# This does not assert that the optimization always gives the same result!