code: def test_underline_based_on_path_prefix():
      doc = StmtBlockDoc(
          [
              ExprStmtDoc(make_id_doc("foo")),
              ExprStmtDoc(make_id_doc("bar")),
          ]
      )
      result = to_python_script(
          doc, path_to_underline=[make_path("foo").attr("x").attr("y")]
      )
      # There is no document that matches the desired path exactly,
      # but path of "foo" is a prefix of the desired path, and thus should be underlined.
      assert result == format_script(
          """
          foo
          ^^^
          bar
      """
      )
  
imports: from typing import Optional
  import pytest
  from tvm.runtime import ObjectPath
  from tvm.script.printer.doc import ExprStmtDoc, IdDoc, OperationDoc, OperationKind, StmtBlockDoc
  from tvm.script.printer.doc_printer import to_python_script
  from tvm.script import ir, tir
label_desc: Use image node_id 12 for calling a global function with example usage: test_underline_based_on_path_prefix() without return types