code: def test_record_video_within_vector():
      envs = gym.vector.SyncVectorEnv(
          [
              make_env("CartPole-v1", 1 + i, render_mode="rgb_array")
              for i in range(2)
          ]
      )
      envs = gym.wrappers.RecordEpisodeStatistics(envs)
      envs.reset()
      for i in range(199):
          _, _, _, _, infos = envs.step(envs.action_space.sample())
  
          # break when every env is done
          if "episode" in infos and all(infos["_episode"]):
              print(f"episode_reward={infos['episode']['r']}")
  
      assert os.path.isdir("videos")
      mp4_files = [
          file for file in os.listdir("videos") if file.endswith(".mp4")
      ]
      assert len(mp4_files) == 2
      shutil.rmtree("videos")
  
file_path: gym/tests/wrappers/test_record_video.py
imports: import os
  import shutil
  import gym
  from gym.wrappers import capped_cubic_video_schedule
label_desc: Use image node_id 5 for calling a global function with example usage: test_record_video_within_vector() without return types