code: def test_prepend_prolog_with_roles_in_sections_without_newline(app):
      # prologue with no trailing line break
      prolog = "this is rst_prolog\nhello reST!"
      content = StringList(
          [":mod:`foo`", "-" * 10, "", "hello"], "dummy.rst"
      )
      prepend_prolog(content, prolog)
  
      assert list(content.xitems()) == [
          ("<rst_prolog>", 0, "this is rst_prolog"),
          ("<rst_prolog>", 1, "hello reST!"),
          ("<generated>", 0, ""),
          ("dummy.rst", 0, ":mod:`foo`"),
          ("dummy.rst", 1, "----------"),
          ("dummy.rst", 2, ""),
          ("dummy.rst", 3, "hello"),
      ]
  
file_path: sphinx/tests/test_util/test_util_rst.py
imports: from docutils.statemachine import StringList
  from jinja2 import Environment
  from sphinx.util.rst import append_epilog, escape, heading, prepend_prolog, textwidth
label_desc: Use image node_id 8 for calling a global function with example usage: test_prepend_prolog_with_roles_in_sections_without_newline(app) without return types