code: def test_log_code_settings(user, test_settings):
      with open("test.py", "w") as f:
          f.write('print("test")')
      settings = test_settings()
      settings.update(
          save_code=True,
          code_dir=".",
          source=wandb.sdk.wandb_settings.Source.INIT,
      )
      with wandb.init(settings=settings) as run:
          pass
  
      artifact_name = wandb.util.make_artifact_name_safe(
          f"source-{run._project}-{run._settings.program_relpath}"
      )
      wandb.Api().artifact(f"{artifact_name}:v0")
  
imports: import json
  from unittest import mock
  import pytest
  import wandb
label_desc: Use image node_id 16 for calling a global function with example usage: test_log_code_settings(user, test_settings) without return types