code: def setup_class(cls):
      deg = [3, 2, 2, 1, 0]
      cls.G = havel_hakimi_graph(deg)
      # Graph used as an example in Sec. 4.1 of Langville and Meyer,
      # "Google's PageRank and Beyond". (Used for test_directed_laplacian)
      cls.DG = nx.DiGraph()
      cls.DG.add_edges_from(
          (
              (1, 2),
              (1, 3),
              (3, 1),
              (3, 2),
              (3, 5),
              (4, 5),
              (4, 6),
              (5, 4),
              (5, 6),
              (6, 4),
          )
      )
  
file_path: networkx/networkx/linalg/tests/test_modularity.py
imports: import pytest
  import networkx
  from networkx.generators.degree_seq import havel_hakimi_graph
label_desc: Use image node_id 1 for calling the TestModularity obj's underlying member method code with example usage: obj.setup_class(cls) without return types