code: def test_cmd_option_starting_with_bracket(app):
      text = ".. option:: [enable=]PATTERN"
      doctree = restructuredtext.parse(app, text)
      assert_node(
          doctree,
          (
              index,
              [
                  desc,
                  (
                      [
                          desc_signature,
                          (
                              [desc_name, "[enable"],
                              [desc_addname, "=]PATTERN"],
                          ),
                      ],
                      [desc_content, ()],
                  ),
              ],
          ),
      )
      objects = list(app.env.get_domain("std").get_objects())
      assert (
          "[enable",
          "[enable",
          "cmdoption",
          "index",
          "cmdoption-arg-enable",
          1,
      ) in objects
  
imports: from unittest import mock
  import pytest
  from docutils import nodes
  from docutils.nodes import definition, definition_list, definition_list_item, term
  from html5lib import HTMLParser
  from sphinx import addnodes
  from sphinx.addnodes import desc, desc_addname, desc_content, desc_name, desc_signature, glossary, index, pending_xref
  from sphinx.domains.std import StandardDomain
  from sphinx.testing import restructuredtext
  from sphinx.testing.util import assert_node
label_desc: Use image node_id 5 for calling a global function with example usage: test_cmd_option_starting_with_bracket(app) without return types