code: def test_multiple_episodes():
      max_steps, grid_size = 20, 3
      n_steps = int(max_steps * 8.25)
      envs = init_several_env(max_steps, grid_size)
  
      for env in envs:
          obs, info = env.reset()
          check_obs(obs, grid_size)
          assert_logger_buffer_size(env, n_steps=0)
  
          step_i = 0
          for _ in range(n_steps):
              step_i += 1
              actions = {
                  policy_id: random.randint(0, env.NUM_ACTIONS - 1)
                  for policy_id in env.players_ids
              }
              obs, reward, done, truncated, info = env.step(actions)
              check_obs(obs, grid_size)
              assert_logger_buffer_size(env, n_steps=step_i)
              assert not done["__all__"] or (
                  step_i == max_steps and done["__all__"]
              )
              if done["__all__"]:
                  obs, info = env.reset()
                  check_obs(obs, grid_size)
                  assert_logger_buffer_size(env, n_steps=0)
                  step_i = 0
  
imports: import random
  import numpy
  from ray.rllib.examples.env.coin_game_non_vectorized_env import CoinGame, AsymCoinGame
label_desc: Use image node_id 8 for calling a global function with example usage: test_multiple_episodes() without return types