code: def testNeighbors(self):
      g = Graph.Famous("petersen")
      g.to_directed()
  
      for i in range(g.vcount()):
          vertex = g.vs[i]
          for mode in "all in out".split():
              self.assertEqual(
                  g.neighbors(i, mode=mode),
                  [edge.index for edge in vertex.neighbors(mode=mode)],
              )
  
imports: import unittest
  from igraph import Graph, Vertex, VertexSeq
  from .utils import is_pypy
label_desc: Use image node_id 7 for calling the VertexTests obj's underlying member method code with example usage: obj.testNeighbors() without return types