class_docstr: Unit tests for :func:`networkx.generators.lattice.grid_2d_graph`
code: def test_periodic_directed(self):
      G = nx.grid_2d_graph(4, 2, periodic=True)
      H = nx.grid_2d_graph(
          4, 2, periodic=True, create_using=nx.DiGraph()
      )
      assert H.succ == G.adj
      assert H.pred == G.adj
  
imports: from itertools import product
  import pytest
  import networkx
  from networkx.utils import edges_equal
label_desc: Use image node_id 7 for calling the TestGrid2DGraph obj's underlying member method code with example usage: obj.test_periodic_directed() without return types