code: def test_in_degree():
      graph = DiGraph()
      nodes = range(4)
      for node in nodes:
          graph.add_node(node)
  
      graph.add_edge(0, 1)
      graph.add_edge(1, 3)
      graph.add_edge(2, 3)
  
      assert [graph.in_degree(node) for node in nodes] == [0, 1, 0, 2]
  
file_path: baikal/tests/_core/test_digraph.py
imports: import pytest
  from baikal._core.digraph import DiGraph, NodeNotFoundError, CyclicDiGraphError
label_desc: Use image node_id 9 for calling a global function with example usage: test_in_degree() without return types