code: def test_vegalite_to_vega_mimebundle(
      engine, vegalite_spec, vega_spec
  ):
      if engine == "vl-convert" and vlc is None:
          pytest.skip(
              "vl_convert not importable; cannot run mimebundle tests"
          )
      elif engine == "altair_saver" and altair_saver is None:
          pytest.skip(
              "altair_saver not importable; cannot run mimebundle tests"
          )
      elif vlc is None and altair_saver is None:
          pytest.skip(
              "Neither altair_saver nor vl_convert are importable;"
              + " cannot run mimebundle tests"
          )
  
      bundle = spec_to_mimebundle(
          spec=vegalite_spec,
          format="vega",
          mode="vega-lite",
          vega_version=alt.VEGA_VERSION,
          vegalite_version=alt.VEGALITE_VERSION,
          vegaembed_version=alt.VEGAEMBED_VERSION,
          engine=engine,
      )
  
      assert bundle == {"application/vnd.vega.v5+json": vega_spec}
  
file_path: altair/tests/utils/test_mimebundle.py
imports: import pytest
  import altair
  from altair import VEGA_VERSION
  from altair.utils.mimebundle import spec_to_mimebundle
label_desc: Use image node_id 3 for calling a global function with example usage: test_vegalite_to_vega_mimebundle(engine, vegalite_spec, vega_spec) without return types