nastavitelny max sollar dle stridace (ulozeno v DB)
Some checks failed
CI and deploy / migration-check (push) Failing after 13s
CI and deploy / deploy (push) Has been skipped

This commit is contained in:
Dusan Vojacek
2026-05-25 11:25:29 +02:00
parent e06f76b9ff
commit c6074e9c74
13 changed files with 101 additions and 17 deletions

View File

@@ -52,6 +52,15 @@ class ComputePvAReg340Tests(unittest.TestCase):
def test_curtail_floor_zero(self) -> None:
self.assertEqual(compute_pv_a_reg340_max_solar_w(10_000, 1000, 5000), 0)
def test_min_clamp_when_positive(self) -> None:
self.assertEqual(
compute_pv_a_reg340_max_solar_w(32_000, 5000, 4600, min_w=400),
400,
)
def test_min_not_applied_when_curtail_to_zero(self) -> None:
self.assertEqual(compute_pv_a_reg340_max_solar_w(10_000, 1000, 5000, min_w=400), 0)
class BuildSetpointsReg340Tests(unittest.TestCase):
def test_with_cap_sets_pv_a_allowed(self) -> None: