class_docstr: A wrapper for running tests in ray ci docker container
class_docstr_tok: ["A","wrapper","for","running","tests","in","ray","ci","docker","container"]
docstr: Create a temporary directory in the current container to store bazel event logs
  produced by the test runs. We do this by using the artifact mount directory from
  the host machine as a shared directory between all containers.
docstr_tok: ["Create","a","temporary","directory","in","the","current","container","to","store","bazel","event","logs","produced","by","the","test","runs",".","We","do","this","by","using","the","artifact","mount","directory","from","the","host","machine","as","a","shared","directory","between","all","containers","."]
code: def _create_bazel_log_mount(
      self, tmp_dir: Optional[str] = None
  ) -> Tuple[str, str]:
      """
      Create a temporary directory in the current container to store bazel event logs
      produced by the test runs. We do this by using the artifact mount directory from
      the host machine as a shared directory between all containers.
      """
      tmp_dir = tmp_dir or "".join(
          random.choice(string.ascii_lowercase) for _ in range(5)
      )
      artifact_host, artifact_container = self.get_artifact_mount()
      bazel_log_dir_host = os.path.join(artifact_host, tmp_dir)
      bazel_log_dir_container = os.path.join(
          artifact_container, tmp_dir
      )
      os.mkdir(bazel_log_dir_container)
      return (bazel_log_dir_host, bazel_log_dir_container)
  
imports: import json
  import os
  import platform
  import random
  import shutil
  import string
  import subprocess
  from typing import List, Tuple, Optional
  from os import path, listdir
  from ci.ray_ci.utils import shard_tests, chunk_into_n
  from ci.ray_ci.utils import logger
  from ci.ray_ci.container import Container
  from ray_release.test import TestResult, Test
label_desc: Use image node_id 2 for calling the TesterContainer obj's underlying member method code with example usage: obj._create_bazel_log_mount(tmp_dir) and returns: bazel_log_dir_host,  bazel_log_dir_container