code: def test_insert_with_version(storage, monkeypatch, script_path):
      """Try to insert a single trial inside a specific version"""
      monkeypatch.chdir(os.path.dirname(os.path.abspath(__file__)))
      orion.core.cli.main(
          [
              "hunt",
              "--init-only",
              "-n",
              "experiment",
              "-c",
              "./orion_config_random.yaml",
              script_path,
              "-x~normal(0,1)",
          ]
      )
      orion.core.cli.main(
          [
              "hunt",
              "--init-only",
              "--enable-evc",
              "-n",
              "experiment",
              "-c",
              "./orion_config_random.yaml",
              script_path,
              "-x~normal(0,1)",
              "-y~+normal(0,1)",
          ]
      )
  
      exp = list(
          storage.fetch_experiments(
              {"name": "experiment", "version": 1}
          )
      )
      assert len(exp) == 1
      exp = exp[0]
      assert "_id" in exp
  
      trials = list(storage.fetch_trials(uid=exp["_id"]))
      assert len(trials) == 0
  
      orion.core.cli.main(
          [
              "insert",
              "-n",
              "experiment",
              "--version",
              "1",
              "-c",
              "./orion_config_random.yaml",
              script_path,
              "-x=1",
          ]
      )
  
      trials = list(storage.fetch_trials(uid=exp["_id"]))
  
      assert len(trials) == 1
  
file_path: orion/tests/functional/commands/test_insert_command.py
imports: import os
  import pytest
  import orion.core.cli
label_desc: Use image node_id 9 for calling a global function with example usage: test_insert_with_version(storage, monkeypatch, script_path) without return types