From 4389aa1ce8f92ba9032d3d1f62a60529cfca2601 Mon Sep 17 00:00:00 2001 From: Ben Elliston Date: Fri, 22 Nov 2024 11:17:42 +1100 Subject: [PATCH] * nemo/sim.py (_dispatch): Mark one unlikely block as 'no cover'. --- nemo/sim.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nemo/sim.py b/nemo/sim.py index e0a76f3b..fc1ee01b 100644 --- a/nemo/sim.py +++ b/nemo/sim.py @@ -100,7 +100,7 @@ def _dispatch(context, hour, residual_hour_demand, gens, generation, spill): else: gen, spl = generator.step(hour, residual_hour_demand) if gen > residual_hour_demand and \ - not isclose(gen, residual_hour_demand): + not isclose(gen, residual_hour_demand): # pragma: no cover msg = (f"generation ({gen:.4f}) > demand " f"({residual_hour_demand:.4f}) for {generator}") raise AssertionError(msg)