diff --git a/tests/test_flatland_malfunction.py b/tests/test_flatland_malfunction.py index 4122d56fc4721b820bcc252b58629cd96f6f8681..2e82d212687b7ef21832ea778ec2dd1552db6b36 100644 --- a/tests/test_flatland_malfunction.py +++ b/tests/test_flatland_malfunction.py @@ -94,16 +94,16 @@ def test_malfunction_process(): obs, all_rewards, done, _ = env.step(actions) if agent_malfunctioning: + # Check that agent is not moving while malfunctioning assert agent_old_position == env.agents[0].position agent_old_position = env.agents[0].position total_down_time += env.agents[0].malfunction_data['malfunction'] - - # Check that the agents breaks twice + # Check that the appropriate number of malfunctions is achieved assert env.agents[0].malfunction_data['nr_malfunctions'] == 5 - # Check that 11 stops where performed + # Check that 20 stops where performed assert agent_halts == 20 # Check that malfunctioning data was standing around