code: def test_wandb_logger_start(self, monkeypatch, trial):
      monkeypatch.setenv(WANDB_ENV_VAR, "9012")
      # API Key in env
      logger = WandbTestExperimentLogger(project="test_project")
      logger.setup()
      # From now on, the API key is in the env variable.
      logger.log_trial_start(trial)
      logger.log_trial_end(trial)
      logger.on_experiment_end(trials=[trial])
  
      logger_state = logger.trial_logging_actor_states[trial]
      assert logger_state.kwargs["project"] == "test_project"
      assert logger_state.kwargs["id"] == trial.trial_id
      assert logger_state.kwargs["name"] == trial.trial_name
      assert logger_state.kwargs["group"] == trial.experiment_dir_name
      assert "config" in logger_state.exclude
  
      del logger
  
      # log config.
      logger = WandbTestExperimentLogger(
          project="test_project", log_config=True
      )
      logger.log_trial_start(trial)
      logger.log_trial_end(trial)
      logger.on_experiment_end(trials=[trial])
  
      logger_state = logger.trial_logging_actor_states[trial]
      assert "config" not in logger_state.exclude
      assert "metric" not in logger_state.exclude
  
      del logger
  
      # Exclude metric.
      logger = WandbTestExperimentLogger(
          project="test_project", excludes=["metric"]
      )
      logger.log_trial_start(trial)
      logger.log_trial_end(trial)
      logger.on_experiment_end(trials=[trial])
  
      logger_state = logger.trial_logging_actor_states[trial]
      assert "config" in logger_state.exclude
      assert "metric" in logger_state.exclude
  
      del logger
  
imports: import gc
  from pathlib import Path
  import numpy
  import os
  import pytest
  import time
  import tempfile
  from unittest.mock import Mock, patch
  import ray
  from ray.exceptions import RayActorError
  from ray.air.integrations.wandb import WandbLoggerCallback, _QueueItem, _WandbLoggingActor
  from ray.air.integrations.wandb import WANDB_ENV_VAR, WANDB_GROUP_ENV_VAR, WANDB_POPULATE_RUN_LOCATION_HOOK, WANDB_PROJECT_ENV_VAR, WANDB_SETUP_API_KEY_HOOK
  from ray.tune.execution.placement_groups import PlacementGroupFactory
  from ray.air.tests.mocked_wandb_integration import _MockWandbAPI, _MockWandbLoggingActor, Trial, WandbTestExperimentLogger, get_mock_wandb_logger
label_desc: Use image node_id 8 for calling the TestWandbLogger obj's underlying member method code with example usage: obj.test_wandb_logger_start(monkeypatch, trial) without return types