code: def test_parallel_runs(
      runner, live_mock_server, test_settings, test_name
  ):
      with runner.isolation():
          with open("train.py", "w") as f:
              f.write(utils.fixture_open("train.py").read())
          p1 = subprocess.Popen(["python", "train.py"], env=os.environ)
          p2 = subprocess.Popen(["python", "train.py"], env=os.environ)
          exit_codes = [p.wait() for p in (p1, p2)]
          assert exit_codes == [0, 0]
          num_runs = 0
          # Assert we've stored 2 runs worth of files
          # TODO: not confirming output.log because it is missing sometimes likely due to a BUG
          # TODO: code saving sometimes doesnt work?
          run_files_sorted = sorted(
              [
                  "config.yaml",
                  f"code/tests/pytest_tests/unit_tests_old/logs/{test_name}/train.py",
                  "requirements.txt",
                  "wandb-metadata.json",
                  "wandb-summary.json",
              ]
          )
          for run, files in live_mock_server.get_ctx()[
              "storage"
          ].items():
              print("Files from server", files)
              # artifacts are stored in the server storage as well so ignore them
              if run == "unknown":
                  continue
              num_runs += 1
              target_files = run_files_sorted
              assert (
                  sorted(
                      f
                      for f in files
                      if not f.endswith(".patch")
                      and not f.endswith("pt.trace.json")
                      and f != "output.log"
                  )
                  == target_files
              )
          assert num_runs == 2
  
file_path: wandb/tests/pytest_tests/unit_tests_old/test_core/test_wandb.py
imports: import importlib
  import os
  import platform
  import subprocess
  import time
  import pytest
  import wandb
  from tests.pytest_tests.unit_tests_old import utils
label_desc: Use image node_id 3 for calling a global function with example usage: test_parallel_runs(runner, live_mock_server, test_settings, test_name) without return types