@@ -56,8 +56,7 @@ async def test_formula_composition( # pylint: disable=too-many-locals
5656 pv_power_recv = pv_pool .power .new_receiver ()
5757
5858 engine = (pv_pool .power + battery_pool .power ).build ("inv_power" )
59- stack .push_async_callback (engine ._stop ) # pylint: disable=protected-access
60-
59+ stack .push_async_callback (engine .stop )
6160 inv_calc_recv = engine .new_receiver ()
6261
6362 await mockgrid .mock_resampler .send_bat_inverter_power ([10.0 , 12.0 , 14.0 ])
@@ -126,7 +125,7 @@ async def test_formula_composition_missing_pv(self, mocker: MockerFixture) -> No
126125 battery_power_recv = battery_pool .power .new_receiver ()
127126 pv_power_recv = pv_pool .power .new_receiver ()
128127 engine = (pv_pool .power + battery_pool .power ).build ("inv_power" )
129- stack .push_async_callback (engine ._stop ) # pylint: disable=protected-access
128+ stack .push_async_callback (engine .stop )
130129
131130 inv_calc_recv = engine .new_receiver ()
132131
@@ -168,7 +167,7 @@ async def test_formula_composition_missing_bat(self, mocker: MockerFixture) -> N
168167 battery_power_recv = battery_pool .power .new_receiver ()
169168 pv_power_recv = pv_pool .power .new_receiver ()
170169 engine = (pv_pool .power + battery_pool .power ).build ("inv_power" )
171- stack .push_async_callback (engine ._stop ) # pylint: disable=protected-access
170+ stack .push_async_callback (engine .stop )
172171
173172 inv_calc_recv = engine .new_receiver ()
174173
@@ -203,15 +202,11 @@ async def test_formula_composition_min_max(self, mocker: MockerFixture) -> None:
203202 stack .push_async_callback (grid .stop )
204203
205204 engine_min = grid .power .min (logical_meter .chp_power ).build ("grid_power_min" )
206- stack .push_async_callback (
207- engine_min ._stop # pylint: disable=protected-access
208- )
205+ stack .push_async_callback (engine_min .stop )
209206 engine_min_rx = engine_min .new_receiver ()
210207
211208 engine_max = grid .power .max (logical_meter .chp_power ).build ("grid_power_max" )
212- stack .push_async_callback (
213- engine_max ._stop # pylint: disable=protected-access
214- )
209+ stack .push_async_callback (engine_max .stop )
215210 engine_max_rx = engine_max .new_receiver ()
216211
217212 await mockgrid .mock_resampler .send_meter_power ([100.0 , 200.0 ])
@@ -265,15 +260,11 @@ async def test_formula_composition_min_max_const(
265260 stack .push_async_callback (grid .stop )
266261
267262 engine_min = grid .power .min (Power .zero ()).build ("grid_power_min" )
268- stack .push_async_callback (
269- engine_min ._stop # pylint: disable=protected-access
270- )
263+ stack .push_async_callback (engine_min .stop )
271264 engine_min_rx = engine_min .new_receiver ()
272265
273266 engine_max = grid .power .max (Power .zero ()).build ("grid_power_max" )
274- stack .push_async_callback (
275- engine_max ._stop # pylint: disable=protected-access
276- )
267+ stack .push_async_callback (engine_max .stop )
277268 engine_max_rx = engine_max .new_receiver ()
278269
279270 await mockgrid .mock_resampler .send_meter_power ([100.0 ])
@@ -320,23 +311,15 @@ async def test_formula_composition_constant( # pylint: disable=too-many-locals
320311 engine_add = (grid .power + Power .from_watts (50 )).build (
321312 "grid_power_addition"
322313 )
323- stack .push_async_callback (
324- engine_add ._stop # pylint: disable=protected-access
325- )
314+ stack .push_async_callback (engine_add .stop )
326315 engine_sub = (grid .power - Power .from_watts (100 )).build (
327316 "grid_power_subtraction"
328317 )
329- stack .push_async_callback (
330- engine_sub ._stop # pylint: disable=protected-access
331- )
318+ stack .push_async_callback (engine_sub .stop )
332319 engine_mul = (grid .power * 2.0 ).build ("grid_power_multiplication" )
333- stack .push_async_callback (
334- engine_mul ._stop # pylint: disable=protected-access
335- )
320+ stack .push_async_callback (engine_mul .stop )
336321 engine_div = (grid .power / 2.0 ).build ("grid_power_division" )
337- stack .push_async_callback (
338- engine_div ._stop # pylint: disable=protected-access
339- )
322+ stack .push_async_callback (engine_div .stop )
340323
341324 engine_composite = (
342325 (
@@ -435,7 +418,7 @@ async def test_3_phase_formulas(self, mocker: MockerFixture) -> None:
435418 engine = (grid .current_per_phase - ev_pool .current_per_phase ).build (
436419 "net_current"
437420 )
438- stack .push_async_callback (engine ._stop ) # pylint: disable=protected-access
421+ stack .push_async_callback (engine .stop )
439422 net_current_recv = engine .new_receiver ()
440423
441424 for _ in range (10 ):
0 commit comments