@@ -331,7 +331,7 @@ def test_redispacth_secondabovepmax(self):
331331
332332 act = self .env .action_space ({"redispatch" : [(2 , 40.0 )]})
333333 obs , reward , done , info = self .env .step (act )
334- assert not info ["failed_redisp " ]
334+ assert not info ["failed_redispatching " ]
335335 assert np .all (obs .target_dispatch == np .array ([0.0 , 0.0 , 60.0 , 0.0 , 0.0 ]))
336336 th_disp = np .array ([0.0 , - 23.5 , 50.4 , 0.0 , - 26.900002 ])
337337 th_disp = np .array ([0. , - 12.977809 , 50.40005 , 0. , - 37.42224 ])
@@ -469,7 +469,7 @@ def test_redispatch_generator_off(self):
469469 redispatch_act = self .env .action_space ({"redispatch" : [(1 , 5.0 )]})
470470 obs , reward , done , info = self .env .step (redispatch_act )
471471
472- assert info ["failed_redisp " ] == True
472+ assert info ["failed_redispatching " ] == True
473473
474474
475475class BaseTestRedispTooLowHigh (MakeBackend ):
@@ -513,12 +513,12 @@ def test_redisp_toohigh_toolow(self):
513513 act = self .env .action_space ({"redispatch" : (0 , - 1 )})
514514 obs , reward , done , info = self .env .step (act )
515515 assert not done
516- assert not info ["failed_redisp " ]
516+ assert not info ["failed_redispatching " ]
517517 assert np .all (self .env ._target_dispatch == [- 1.0 , 0.0 , 0.0 , 0.0 , 0.0 ])
518518 act = self .env .action_space ({"redispatch" : (0 , 0 )})
519519 obs , reward , done , info = self .env .step (act )
520520 assert not done
521- assert not info ["failed_redisp " ]
521+ assert not info ["failed_redispatching " ]
522522 assert np .all (self .env ._target_dispatch == [- 1.0 , 0.0 , 0.0 , 0.0 , 0.0 ])
523523
524524 # this one is not correct: too high decrease
@@ -527,7 +527,7 @@ def test_redisp_toohigh_toolow(self):
527527 )
528528 obs , reward , done , info = self .env .step (act )
529529 assert not done
530- assert info ["failed_redisp " ]
530+ assert info ["failed_redispatching " ]
531531 assert np .all (self .env ._target_dispatch == [- 1.0 , 0.0 , 0.0 , 0.0 , 0.0 ])
532532
533533 # this one is not correct: too high increase
@@ -536,7 +536,7 @@ def test_redisp_toohigh_toolow(self):
536536 )
537537 obs , reward , done , info = self .env .step (act )
538538 assert not done
539- assert info ["failed_redisp " ]
539+ assert info ["failed_redispatching " ]
540540 assert np .all (self .env ._target_dispatch == [- 1.0 , 0.0 , 0.0 , 0.0 , 0.0 ])
541541
542542 def test_error_message_notzerosum_oneshot (self ):
@@ -551,22 +551,22 @@ def test_error_message_notzerosum_oneshot(self):
551551 }
552552 )
553553 obs , reward , done , info = self .env .step (act )
554- assert info ["failed_redisp " ]
554+ assert info ["failed_redispatching " ]
555555 assert info ["exception" ][0 ].__str__ ()[:140 ] == self .msg_
556556
557557 def test_error_message_notzerosum_threesteps (self ):
558558 self .skipTest ("Ok with new redispatching implementation" )
559559 act = self .env .action_space ({"redispatch" : [(0 , 4.9999784936326535 )]})
560560 obs , reward , done , info = self .env .step (act )
561- assert info ["failed_redisp " ] is False
561+ assert info ["failed_redispatching " ] is False
562562
563563 act = self .env .action_space ({"redispatch" : [(1 , 4.78524395611872 )]})
564564 obs , reward , done , info = self .env .step (act )
565- assert info ["failed_redisp " ] is False
565+ assert info ["failed_redispatching " ] is False
566566
567567 act = self .env .action_space ({"redispatch" : [(4 , - 9.999591852954794 )]})
568568 obs , reward , done , info = self .env .step (act )
569- assert info ["failed_redisp " ]
569+ assert info ["failed_redispatching " ]
570570 assert info ["exception" ][0 ].__str__ ()[:140 ] == self .msg_
571571
572572
0 commit comments