code: def test_reverse_method_signature(geocoder_cls):
      # `reverse` method is optional.
      method = geocoder_cls.reverse
      sig = inspect.signature(method)
  
      assert_no_varargs(sig)
  
      # First arg (except self) must be called `query`:
      sig_query = list(sig.parameters.values())[1]
      assert sig_query.name == "query"
      assert sig_query.kind == inspect.Parameter.POSITIONAL_OR_KEYWORD
  
      # The rest must be kwargs-only:
      sig_kwargs = list(sig.parameters.values())[2:]
      assert all(
          p.kind == inspect.Parameter.KEYWORD_ONLY for p in sig_kwargs
      ), (
          "All method args except `query` must be keyword-only "
          "(i.e. separated with an `*`)."
      )
  
      # kwargs must contain `exactly_one`:
      sig_exactly_one = sig.parameters["exactly_one"]
      assert (
          sig_exactly_one.default is True
      ), "`exactly_one` must be True"
  
      # kwargs must contain `timeout`:
      sig_timeout = sig.parameters["timeout"]
      assert (
          sig_timeout.default is DEFAULT_SENTINEL
      ), "`timeout` must be DEFAULT_SENTINEL"
  
      assert_rst(
          sig,
          method.__doc__,
          allowed_rtypes=[
              ":class:`geopy.location.Location` or a list of them, "  # what3words
              "if ``exactly_one=False``.",
              "``None``, :class:`geopy.location.Location` or a list of them, "
              "if ``exactly_one=False``.",
          ],
      )
  
file_path: geopy/test/geocoders/__init__.py
imports: import importlib
  import inspect
  import pkgutil
  import docutils.core
  import docutils.utils
  import pytest
  import geopy.geocoders
  from geopy.geocoders.base import DEFAULT_SENTINEL, Geocoder
label_desc: Use image node_id 9 for calling a global function with example usage: test_reverse_method_signature(geocoder_cls) without return types