code: def test_to_json_remove_uids(fig1):
      dict1 = fig1.to_dict()
      for trace in dict1["data"]:
          trace.pop("uid", None)
  
      assert pio.to_json(fig1) == json.dumps(dict1, **opts)
  
imports: import plotly.graph_objs
  import plotly.io
  import pytest
  import plotly
  import json
  import os
  import tempfile
  from unittest.mock import MagicMock
  from pathlib import Path
label_desc: Use image node_id 3 for calling a global function with example usage: test_to_json_remove_uids(fig1) without return types