code: def test_info_to_list():
      env_to_wrap = gym.vector.make(
          ENV_ID, num_envs=NUM_ENVS, disable_env_checker=True
      )
      wrapped_env = VectorListInfo(env_to_wrap)
      wrapped_env.action_space.seed(SEED)
      _, info = wrapped_env.reset(seed=SEED)
      assert isinstance(info, list)
      assert len(info) == NUM_ENVS
  
      for _ in range(ENV_STEPS):
          action = wrapped_env.action_space.sample()
          _, _, terminateds, truncateds, list_info = wrapped_env.step(
              action
          )
          for i, (terminated, truncated) in enumerate(
              zip(terminateds, truncateds)
          ):
              if terminated or truncated:
                  assert "final_observation" in list_info[i]
              else:
                  assert "final_observation" not in list_info[i]
  
imports: import pytest
  import gym
  from gym.wrappers import RecordEpisodeStatistics, VectorListInfo
label_desc: Use image node_id 2 for calling a global function with example usage: test_info_to_list() without return types