code: def test_literalinclude_pydecorators(app, status, warning):
      app.build(filenames=[app.srcdir / "py-decorators.rst"])
      et = etree_parse(app.outdir / "py-decorators.xml")
      secs = et.findall("./section/section")
  
      literal_include = secs[0].findall("literal_block")
      assert len(literal_include) == 3
  
      actual = literal_include[0].text
      expect = (
          "@class_decorator\n"
          "@other_decorator()\n"
          "class TheClass(object):\n"
          "\n"
          "    @method_decorator\n"
          "    @other_decorator()\n"
          "    def the_method():\n"
          "        pass\n"
      )
      assert actual == expect
  
      actual = literal_include[1].text
      expect = (
          "    @method_decorator\n"
          "    @other_decorator()\n"
          "    def the_method():\n"
          "        pass\n"
      )
      assert actual == expect
  
      actual = literal_include[2].text
      expect = (
          "@function_decorator\n"
          "@other_decorator()\n"
          "def the_function():\n"
          "    pass\n"
      )
      assert actual == expect
  
imports: import os.path
  import pytest
  from docutils import nodes
  from sphinx.config import Config
  from sphinx.directives.code import LiteralIncludeReader
  from sphinx.testing.util import etree_parse
label_desc: Use image node_id 40 for calling a global function with example usage: test_literalinclude_pydecorators(app, status, warning) without return types