code: def test_inject_current_ray(self):
      # Should not be injected if not provided by env var.
      result = RuntimeEnv(env_vars={"hi": "hi"})
      assert "_inject_current_ray" not in result
  
      os.environ["RAY_RUNTIME_ENV_LOCAL_DEV_MODE"] = "1"
  
      # Should be injected if provided by env var.
      result = RuntimeEnv()
      assert result["_inject_current_ray"]
  
      # Should be preserved if passed.
      result = RuntimeEnv(_inject_current_ray=False)
      assert not result["_inject_current_ray"]
  
      del os.environ["RAY_RUNTIME_ENV_LOCAL_DEV_MODE"]
  
imports: import os
  import pytest
  import sys
  import tempfile
  from pathlib import Path
  from ray import job_config
  import yaml
  import jsonschema
  from ray._private.runtime_env.validation import parse_and_validate_excludes, parse_and_validate_working_dir, parse_and_validate_conda, parse_and_validate_pip, parse_and_validate_env_vars, parse_and_validate_py_modules
  from ray._private.runtime_env.plugin_schema_manager import RuntimeEnvPluginSchemaManager
  from ray.runtime_env import RuntimeEnv
label_desc: Use image node_id 5 for calling the TestParsedRuntimeEnv obj's underlying member method code with example usage: obj.test_inject_current_ray() without return types