code: def test_singleton(self, graph):
      G = graph()
      G.add_node("x")
      assert nx.spectral_ordering(G) == ["x"]
      G.add_edge("x", "x", weight=33)
      G.add_edge("x", "x", weight=33)
      assert nx.spectral_ordering(G) == ["x"]
  
imports: from math import sqrt
  import pytest
  import networkx
label_desc: Use image node_id 2 for calling the TestSpectralOrdering obj's underlying member method code with example usage: obj.test_singleton(graph) without return types