class_docstr: A subclass of :class:`Sphinx` that runs on the test root, with some
  better default values for the initialization parameters.
code: def cleanup(self, doctrees: bool = False) -> None:
      # ModuleAnalyzer.cache.clear()
      # locale.translators.clear()
      # sys.path[:] = self._saved_path
      # sys.modules.pop('autodoc_fodder', None)
      # directives._directives.clear()  # type: ignore[attr-defined]
      # roles._roles.clear()  # type: ignore[attr-defined]
      # for node in additional_nodes:
      #     delattr(nodes.GenericNodeVisitor, f'visit_{node.__name__}')
      #     delattr(nodes.GenericNodeVisitor, f'depart_{node.__name__}')
      #     delattr(nodes.SparseNodeVisitor, f'visit_{node.__name__}')
      #     delattr(nodes.SparseNodeVisitor, f'depart_{node.__name__}')
      # additional_nodes.clear()
      with contextlib.suppress(FileNotFoundError):
          os.remove(self.docutils_conf_path)
  
imports: from __future__ import annotations
  import contextlib
  import os
  import re
  import sys
  import warnings
  from typing import IO, TYPE_CHECKING, Any
  from xml.etree import ElementTree
  from docutils import nodes
  from sphinx import application
label_desc: Use image node_id 2 for calling the SphinxTestApp obj's underlying member method code with example usage: obj.cleanup(doctrees) without return types