code: def testProxyMethods(self):
      # We only test with connected graphs because disconnected graphs might
      # print a warning when distances() is invoked on them and we want
      # to avoid that in the test output.
      while True:
          g = Graph.GRG(10, 0.6)
          if g.is_connected():
              break
  
      v = g.vs[0]
  
      # - neighbors(), predecessors() and succesors() are ignored because they
      #   return vertex lists while the methods in Graph return vertex index
      #   lists.
      # - incident(), all_edges(), in_edges() and out_edges() are ignored
      #   because it returns an edge list while the methods in Graph return
      #   edge indices.
      # - pagerank() and personalized_pagerank() are ignored because of numerical
      #   inaccuracies
      # - shortest_paths() is ignored because it's a deprecated alias
      # - delete() is ignored because it mutates the graph
      ignore = (
          "neighbors predecessors successors pagerank personalized_pagerank"
          " delete incident all_edges in_edges out_edges shortest_paths"
      )
      ignore = set(ignore.split())
  
      # Methods not listed here are expected to return an int or a float
      return_types = {"distances": list, "get_shortest_paths": list}
  
      for name in Vertex.__dict__:
          if name in ignore:
              continue
  
          func = getattr(v, name)
          docstr = func.__doc__
  
          if not docstr.startswith("Proxy method"):
              continue
  
          result = func()
          self.assertEqual(
              getattr(g, name)(v.index),
              result,
              msg=("Vertex.%s proxy method misbehaved" % name),
          )
  
          return_type = return_types.get(name, (int, float))
          self.assertTrue(
              isinstance(result, return_type),
              msg=(
                  "Vertex.%s proxy method did not return %s"
                  % (name, return_type)
              ),
          )
  
imports: import unittest
  from igraph import Graph, Vertex, VertexSeq
  from .utils import is_pypy
label_desc: Use image node_id 8 for calling the VertexTests obj's underlying member method code with example usage: obj.testProxyMethods() without return types