code: def __init__(self, api, config):
      self.api = api
      self.config = config
  
file_path: wandb/tests/pytest_tests/unit_tests/test_launch/test_agent/test_config.py
imports: from unittest.mock import MagicMock
  import pytest
  from wandb.sdk.launch._launch import create_and_run_agent
  from wandb.sdk.launch.errors import LaunchError
label_desc: Use image node_id 1 to create a new MockAgent object  with example: obj = MockAgent(api, config)