code: def test_to_dot():
      arr = mt.random.randint(10, size=(10, 8), chunk_size=4)
      arr_add = mt.random.randint(10, size=(10, 8), chunk_size=4)
      arr2 = arr + arr_add
      graph = arr2.build_graph(fuse_enabled=False, tile=True)
  
      dot = to_str(graph.to_dot(trunc_key=5))
      assert all(to_str(n.key)[:5] in dot for n in graph) is True
  
file_path: mars/mars/core/graph/tests/test_graph.py
imports: import pytest
  import numpy
  from ....None import dataframe
  from ....None import tensor
  from ....tests.core import flaky
  from ....utils import to_str
  from ..None import DAG, GraphContainsCycleError
label_desc: Use image node_id 2 for calling a global function with example usage: test_to_dot() without return types