code: def test_basic_chart_from_dict(alt, basic_spec):
      chart = alt.Chart.from_dict(basic_spec)
      dct = chart.to_dict()
  
      # schema should be in the top level
      assert dct.pop("$schema").startswith("http")
  
      # remainder of spec should match the basic spec
      assert dct == make_final_spec(alt, basic_spec)
  
file_path: altair/tests/vegalite/test_common.py
imports: import pytest
  import pandas
  from altair.vegalite import v5
label_desc: Use image node_id 5 for calling a global function with example usage: test_basic_chart_from_dict(alt, basic_spec) without return types