code: def test_describe_input_all_components_have_inputs():
      A = component_class(
          "A", input_types={"x": Optional[int]}, output={"x": 0}
      )
      B = component_class("B", input_types={"y": int}, output={"y": 0})
      C = component_class(
          "C", input_types={"x": int, "y": int}, output={"z": 0}
      )
      p = Pipeline()
      p.add_component("a", A())
      p.add_component("b", B())
      p.add_component("c", C())
      p.connect("a.x", "c.x")
      p.connect("b.y", "c.y")
      assert p.inputs() == {
          "a": {"x": {"type": Optional[int], "is_mandatory": True}},
          "b": {"y": {"type": int, "is_mandatory": True}},
      }
  
imports: from typing import Optional
  import logging
  import pytest
  from haystack.core.pipeline import Pipeline
  from haystack.core.component.sockets import InputSocket, OutputSocket
  from haystack.core.errors import PipelineMaxLoops, PipelineError, PipelineRuntimeError
  from haystack.testing.sample_components import AddFixedValue, Threshold, Double, Sum
  from haystack.testing.factory import component_class
label_desc: Use image node_id 14 for calling a global function with example usage: test_describe_input_all_components_have_inputs() without return types