code: def test_fetcher_json() -> None:
      dirpath = tempfile.mkdtemp()
      try:
          json_path = dirpath + "/xp.json"
          with Path(json_path).open("w+", encoding="utf-8") as tmpf:
              json.dump(
                  [
                      {"id": 1, "metric": 1.0, "param": "abc"},
                      {
                          "id": 2,
                          "metric": 1.0,
                          "param": "abc",
                          "option": "def",
                      },
                  ],
                  tmpf,
              )
          xp = load_json(json_path)
          xp.validate()
          assert xp.datapoints
          assert len(xp.datapoints) == 2
      finally:
          shutil.rmtree(dirpath)
  
file_path: hiplot/hiplot/test_fetchers.py
imports: from pathlib import Path
  import json
  import tempfile
  import shutil
  import pytest
  from .None import experiment
  from .fetchers import load_demo, load_csv, load_json, MultipleFetcher, get_fetchers, load_xps_with_fetchers
  from .fetchers_demo import README_DEMOS
label_desc: Use image node_id 3 for calling a global function with example usage: test_fetcher_json() without return types