code: def test_from_dict_without_expected_type():
      data = {
          "type": "haystack.testing.sample_components.merge_loop.MergeLoop",
          "init_parameters": {"inputs": ["first", "second"]},
      }
      with pytest.raises(DeserializationError) as exc:
          MergeLoop.from_dict(data)
  
      exc.match("Missing 'expected_type' field in 'init_parameters'")
  
file_path: haystack/test/core/sample_components/test_merge_loop.py
imports: from typing import Dict
  import pytest
  from haystack.core.errors import DeserializationError
  from haystack.testing.sample_components import MergeLoop
label_desc: Use image node_id 7 for calling a global function with example usage: test_from_dict_without_expected_type() without return types